Git Product home page Git Product logo

xunnamius / babel-plugin-explicit-exports-references Goto Github PK

View Code? Open in Web Editor NEW
19.0 19.0 3.0 998 KB

⚡ Transforms all internal references to a module's exports such that each reference starts with "module.exports" instead of directly referencing an internal name.

Home Page: https://npm.im/babel-plugin-explicit-exports-references

License: MIT License

JavaScript 50.21% TypeScript 49.79%
babel default each explicit export exports function jest mock module other refer reference references same test

babel-plugin-explicit-exports-references's People

Contributors

dependabot[bot] avatar xunnamius avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

playvs-inc khan

babel-plugin-explicit-exports-references's Issues

License?

Aloha! Thank you for crafting this plugin. Extremely helpful. I was just curious if you had a particular license file in mind/plan to add to repo?

Breaks ES Modules

When transpiling to ES Modules (including setting "type": "module" in package.json) this breaks Jest tests with the error:

ReferenceError: module is not defined

It seems it doesn't take the targeted build type into account and just assumes it's building CommonJS modules. I know the options are limited and I'm not certain what the best solution is, but since ES Module adoption is only increasing it would be nice to have the option to not produce a broken build with Jest. Just wanted to at least raise the issue for consideration.

Can cause problems for istanbul when computing coverage

Errors look like:

ReferenceError: /repos/xscripts/src/assets/config/_conventional.config.js.ts: Container is falsy

This is probably due to the naive way new variables are created. Either way, this old project needs some of my attention!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.