handlebars-variables-extract
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

Extract variables from handlebars

Usage

git clone https://github.com/a-owl/handlebars-variables-extract.git YOURFOLDERNAME
cd YOURFOLDERNAME
 
# Run npm install and write your library name when asked. That's all! 
npm install handlebars-variables-extract
import extract from 'handlebars-variables-extract';
extract(`{{template}}`);

like JSON schema https://json-schema.org/

Contributing

NPM scripts

  • npm t: Run test suite
  • npm start: Run npm run build in watch mode
  • npm run test:watch: Run test suite in interactive watch mode
  • npm run test:prod: Run linting and generate coverage
  • npm run build: Generate bundles and typings, create docs
  • npm run lint: Lints code
  • npm run commit: Commit using conventional commit style (husky will tell you to use it if you haven't 😉)

Excluding peerDependencies

On library development, one might want to set some peer dependencies, and thus remove those from the final bundle. You can see in Rollup docs how to do that.

Good news: the setup is here for you, you must only include the dependency name in external property within rollup.config.js. For example, if you want to exclude lodash, just write there external: ['lodash'].

This project refer to barhandles.

Contributions of any kind are welcome!

Package Sidebar

Install

npm i handlebars-variables-extract

Weekly Downloads

172

Version

1.0.0

License

MIT

Unpacked Size

35.1 kB

Total Files

8

Last publish

Collaborators

  • panzj