Skip to content
No description, website, or topics provided.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
yarn.lock v1.0.0 Apr 29, 2019

NPM Version GitHub release npm downloads


Simple parser for vue files

Using require-extension-hooks you can transpile ES6/7/.. code to run in node. Although node supports 99.999% of ES6 features there is one major omission: export/import syntax.


npm install require-extension-hooks require-extension-hooks-babel --save-dev


const hooks = require('require-extension-hooks');
hooks('js').plugin('babel', {}).push();

// elsewhere...
import {foo} from './foo';

The second argument allows you to configure which options are passed into babel's transform function. By default this contains a node : current configuration to only use babel polyfills that node doesn't have.

You can’t perform that action at this time.