question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

strongly-recommended rules fails with vue-types

See original GitHub issue

Hi,

thanks for the great effort on this library!

I’m the author of a React’s prop-types-like library for vue called vue-types.

I’ve been contacted by a user which reported an issue using vue-types with eslint-plugin-vue rules.

Basically the library generates a prop object at runtime, but that’s not picked up by some rules like require-default-prop. If I got it right, since eslint it’s a static analyzer, it cannot manage runtime code (even if resolvers like those in eslint-plugin-import seems to somehow be able to do it).

I’m looking for a way to make this setup work without needing to disable the eslint rule which is pretty important from my point of view.

Any suggestion on where to start?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
michalsnikcommented, Jul 11, 2018

Good job @dwightjack ! Happy you figured it out 😃 I guess we can close this issue now

0reactions
dwightjackcommented, Apr 17, 2018

Hi,

as an follow up to this issue I’ve released a plugin to whitelist vue-types’s definitions: https://github.com/dwightjack/eslint-plugin-vue-types

Feedbacks are welcome

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to get all rules as json of vue/strongly-recommended
I am currently using WebStorm and it gives it own linting errors as there is no way I an give a configuration file...
Read more >
Available rules - eslint-plugin-vue
Rule ID Description vue/multi‑word‑component‑names require component names to be always multi‑word... vue/no‑arrow‑functions‑in‑watch disallow using arrow functions to define watcher... vue/no‑computed‑properties‑in‑data disallow accessing computed properties in data...
Read more >
eslint-plugin-vue-types
In your eslint configuration add plugin:vue-types/strongly-recommended after any plugin:vue/* preset. module.exports = { extends: [ // .
Read more >
Eslint-plugin-vue-types NPM | npm.io
The rule extends vue/require-default-prop preventing it from reporting errors for props defined with VueTypes namespaced validators (like VueTypes.string or ...
Read more >
Vue.js eslint Parsing error .: unexpected token
I am getting this error on a state.js file ( at => in the const ... to `plugin:vue/strongly-recommended` or `plugin:vue/recommended` for ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found