Plugin lookup path
See original GitHub issueI’m trying to update documentation.js to babel 6: one of the issues I’m seeing is this:
/Users/tmcw/src/documentation/bin/documentation.js:32
throw err;
^
ReferenceError: Unknown plugin "es2015" specified in "base" at 0, attempted to resolve relative to "/Users/tmcw/src/documentation/test/fixture" while parsing file: /Users/tmcw/src/documentation/test/fixture/es6.input.js
at /Users/tmcw/src/documentation/node_modules/babel-core/lib/transformation/file/options/option-manager.js:193:17
at Array.map (native)
at Function.normalisePlugins (/Users/tmcw/src/documentation/node_modules/babel-core/lib/transformation/file/options/option-manager.js:173:20)
at OptionManager.mergeOptions (/Users/tmcw/src/documentation/node_modules/babel-core/lib/transformation/file/options/option-manager.js:271:36)
at OptionManager.init (/Users/tmcw/src/documentation/node_modules/babel-core/lib/transformation/file/options/option-manager.js:416:10)
at File.initOptions (/Users/tmcw/src/documentation/node_modules/babel-core/lib/transformation/file/index.js:190:75)
at new File (/Users/tmcw/src/documentation/node_modules/babel-core/lib/transformation/file/index.js:121:22)
at Pipeline.transform (/Users/tmcw/src/documentation/node_modules/babel-core/lib/transformation/pipeline.js:42:16)
at Babelify._flush (/Users/tmcw/src/documentation/node_modules/babelify/index.js:28:24)
at Babelify.<anonymous> (_stream_transform.js:118:12)
I want to use babelify and presets as a module in a binary package: so there’s a file at, say, lib/lookup.js
that uses babelify
’s node interface and configures it with presets. How do I tell babelify where to look for presets?
Issue Analytics
- State:
- Created 8 years ago
- Comments:6 (4 by maintainers)
Top Results From Across the Web
Lookup plugins - Ansible Documentation
Lookup plugins are an Ansible-specific extension to the Jinja2 templating language. You can use lookup plugins to access data from outside sources (files, ......
Read more >How to use the lookup plugin to get the directory path and file ...
My issue is I created a task that create a new directory with a timestamp to store the relevant data, I was able...
Read more >Plugin search paths | Substance 3D Designer - 3D & AR
Manually adding plugin search paths · Go to the 'Edit/Preferences...' panel; · Select the 'Projects' category; · Select the 'Project File' you want ......
Read more >Lookup Plugins — Ansible Documentation
Lookups are executed with a working directory relative to the role or play, as opposed to local tasks, which are executed relative the...
Read more >Deep Dive into Lookup Plugins in Ansible with Example
Lookup plugins allow Ansible to access data from outside sources. · Like all templating, these plugins are evaluated on the Ansible control ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I think presets are resolved relative to the
.babelrc
file or CWD. But if you’re configuring it via Node you should be able to also just require in the preset if you need to, e.g..transform(babelify, {presets: [require("/some/path")]})
. Are you sure the issue you’re running into isn’t just specifying it as a plugin instead of a preset?:Unknown plugin "es2015"
Hm, I don’t think babelify can help with plugin path resolution - that’s just how babel works.