GithubHelp home page GithubHelp logo

amilajack / babel-plugin-fail-explicit Goto Github PK

View Code? Open in Web Editor NEW
7.0 3.0 3.0 872 KB

A babel plugin that prevents coercion and silent failure in JavaScript

License: MIT License

JavaScript 100.00%
babel plugin fail explicit coercion safe silent failure

babel-plugin-fail-explicit's Issues

Add support for es6 destructuring

Example

const some = {}
const { foo } = some
// ^^^ Fails silently

Transformation

const some = {}
const foo = safePropertyAccess(['foo'], some)
// TypeError: Property "foo" does not exist in "Object"

safeCoerce: Blacklisting vs Whitelisting

Not 100% sure what the code's intention is, but I think you want to apply it only to operations like +, -, *, ..., but not apply it to comparisons.

I would definitely rather whitelist the supported operators than blacklisting the unsupported ones, since there is a real chance you miss something or tomorrow someone adds a new operator that breaks stuff.

Consider '<', for instance. It's also a comparison, but maybe I missed your intention here ๐Ÿ˜‰

Dependency Dashboard

This issue provides visibility into Renovate updates and their statuses. Learn more

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.


  • Check this box to trigger a request for Renovate to run again on this repository

Action Required: Fix Renovate Configuration

There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.

Location: package.json
Error type: The renovate configuration file contains some invalid settings
Message: Configuration option 'packageRules[2].node' should be a json object, Invalid configuration option: author, Invalid configuration option: babel, Invalid configuration option: bugs, Invalid configuration option: engineStrict, Invalid configuration option: eslintConfig, Invalid configuration option: files, Invalid configuration option: homepage, Invalid configuration option: jest, Invalid configuration option: keywords, Invalid configuration option: license, Invalid configuration option: main, Invalid configuration option: name, Invalid configuration option: packageRules[0].@babel/helper-module-imports, Invalid configuration option: packageRules[0].safe-access-check, Invalid configuration option: packageRules[1].@babel/cli, Invalid configuration option: packageRules[1].@babel/core, Invalid configuration option: packageRules[1].@babel/plugin-transform-modules-commonjs, Invalid configuration option: packageRules[1].@babel/plugin-transform-modules-umd, Invalid configuration option: packageRules[1].@babel/plugin-transform-runtime, Invalid configuration option: packageRules[1].@babel/preset-env, Invalid configuration option: packageRules[1].@babel/preset-flow, Invalid configuration option: packageRules[1].@babel/traverse, Invalid configuration option: packageRules[1].@babel/types, Invalid configuration option: packageRules[1].babel-eslint, Invalid configuration option: packageRules[1].babel-plugin-add-module-exports, Invalid configuration option: packageRules[1].babel-plugin-transform-async-to-bluebird, Invalid configuration option: packageRules[1].babel-plugin-transform-promise-to-bluebird, Invalid configuration option: packageRules[1].cross-env, Invalid configuration option: packageRules[1].eslint, Invalid configuration option: packageRules[1].eslint-config-bliss, Invalid configuration option: packageRules[1].flow-bin, Invalid configuration option: packageRules[1].flow-typed, Invalid configuration option: packageRules[1].jest, Invalid configuration option: renovate, Invalid configuration option: scripts, Invalid configuration option: version, The "node" object can only be configured at the top level of a config but was found inside "packageRules[2]"

Dependency deprecation warning: babel-preset-es2015 (npm)

On registry https://registry.npmjs.org/, the "latest" version (v6.24.1) of dependency babel-preset-es2015 has the following deprecation notice:

๐Ÿ™Œ Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update!

Marking the latest version of an npm package as deprecated results in the entire package being considered deprecated, so contact the package author you think this is a mistake.

Affected package file(s): package.json

If you don't care about this, you can close this issue and not be warned about babel-preset-es2015's deprecation again. If you would like to completely disable all future deprecation warnings then add the following to your config:

"suppressNotifications": ["deprecationWarningIssues"]

Prefix methods

safeCoerce -> _safeCoerce. Helps avoid possible naming collisions

Dependency deprecation warning: babel-preset-es2015 (npm)

On registry https://registry.npmjs.org/, the "latest" version (v6.24.1) of dependency babel-preset-es2015 has the following deprecation notice:

๐Ÿ™Œ Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update!

Marking the latest version of an npm package as deprecated results in the entire package being considered deprecated, so contact the package author you think this is a mistake.

Affected package file(s): package.json

If you don't care about this, you can close this issue and not be warned about babel-preset-es2015's deprecation again. If you would like to completely disable all future deprecation warnings then add the following to your config:

"suppressNotifications": ["deprecationWarningIssues"]

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.