invariant icon indicating copy to clipboard operation
invariant copied to clipboard

invariant

Results 16 invariant issues
Sort by recently updated
recently updated
newest added

Hello, I would like to ask how you came up with the idea of developing this library in the first place, and why the name is called invariant

The flow type definition says that the `format` argument is optional, but it's not. At least in dev mode, when `format` is missing invariant throws an error.

We throw an error when `format` is missing. Fixes: #27

**Issue**: We detected vulnerable dependencies in your project by using the command “npm audit”: #### npm audit report cryptiles

I get this Error: `Invariant Violation: Module is not a registered callable module (calling onShouldStartLoadWithRequest)`

Hi @zertosh, Don't know if this repo is still under maintainence. Anyway, I've noticed that it uses `a, b, c, d, e` as placeholders for the `%s` to be replaced....

Sorry to ask a naive question, but I really scratching my hair right now. Can you enlighten me how The invariant message will be stripped in production? I read this...

invariant is using a defined number of arguments `(a,b,c,d,e,f)` imo it should be ```js invariant(cond, message, ...args) { const parsed = message.replace('%s', () => args.shift() || '') } ```

`invariant` only provides a CommonJS interface (`exports = function()`). Unfortunately, this will fail if it is used in an ES Module environment (for instance, [in `jsxstyle`](https://github.com/smyte/jsxstyle/pull/83)). I don't know enough...

Hi, https://github.com/zertosh/invariant/blob/master/invariant.js#L46 ```javascript error.framesToPop = 1 ``` Can the `framesToPop` be renamed to anything people want ? Have some info/refer links about `framesToPop`, please mark. ths.