New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
context.options not getting the values #339
Comments
Try this: -'unicorn/myrule': 'error', [ {name: 'hello'}]
+'unicorn/myrule': ['error', {name: 'hello'}] |
@futpib my fault, it was already that way. :( doesn't work. |
I will edit it to my version. |
Here is an example of a test with custom options: eslint-plugin-unicorn/test/catch-error-name.js Lines 304 to 318 in 4c3d61c
|
That's exactly what I was missing, thanks.:) |
While developing the rule, in
index.js
when I doand in
rules/myrule.js
I just did a simpleconsole.log(context.options[0])
and it is comingundefined
all the time when I wrote a simple test and ran it usingnpx ava test/myrule.js
.Am I doing something wrong to pass options?
PS:
console.log('hello')
works fine.The text was updated successfully, but these errors were encountered: