This is a step-by-step guide on how to get started with Esmbly.
Esmbly is all about statically typed JavaScript so before you get started, make sure you have Node.js and npm installed.
Navigate to the project where you want to run Esmbly. If the project does not contain a package.json
, run npm init
to create one.
cd my-project
npm init
The easiest way to install and configure Esmbly is to use npx. The init command will ask about which transformers you want to use, create a configuration file and (optionally) install any necessary dependencies.
npx @esmbly/cli init
Optionally, you could install @esmbly/cli
yourself then use the init command to create a configuration file (or create one manually). Make sure to install the transformers you want to use as well.
# Using Yarn:
yarn add @esmbly/cli --dev
yarn run esmbly init
# Or, using NPM:
npm install @esmbly/cli--save-dev
./node_modules/.bin/esmbly init
If you ran the init
command, a config file called esmbly.config.js
has automatically been created in the root of your project (e.g. next to your package.json
) based on your input.
Most transformers should work out of the box, without the need for any further configuration. Look at the documentation for your selected transformers for details about how to use them and the possible configuration options.
# Using Yarn:
yarn run esmbly run
# Using NPM:
./node_modules/.bin/esmbly run
# Or, using NPX:
npx esmbly run
- Check out Using the CLI for further details about how to configure Embly.
- Look at the documentation for your selected transformers for details about how to use them.