@financial-times/dotcom-build-esnext v0.3.5
@financial-times/dotcom-build-esnext
This package extends the Page Kit CLI build action (page-kit build
) with the ability to build JavaScript that makes use of features that fall under the esnext
banner
Getting started
This package is compatible with Node 8+ and is distributed on npm.
npm install --save-dev @financial-times/dotcom-build-esnext
After installing the package you must add it to the list of plugins in your project's page-kit.config.js
configuration file:
+ const esnext = require('@financial-times/dotcom-build-esnext')
module.exports = {
plugins: [
+ esnext.plugin()
]
}
Once setup, this plugin will enable you to use the following esnext
features within your JavaScript code.
Options
There are currently no additional options for this plugin.
Hooks
This plugin exposes the following hooks as extension points. They are available as constants on the exported hooks
object.
import { hooks } from '@financial-times/dotcom-build-esnext'
Please note: The hooks below are listed in the order they will be executed.
BABEL_PLUGIN_CLASS_PROPERTIES_OPTIONS
Configuration options for the @babel/plugin-proposal-class-properties plugin.
BABEL_PLUGIN_SYNTAX_DYNAMIC_IMPORT_OPTIONS
Configuration options for the @babel/plugin-syntax-dynamic-import plugin.
BABEL_PLUGIN_TRANSFORM_RUNTIME_OPTIONS
Configuration options for the @babel/plugin-transform-runtime plugin.
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago