Closed PlastMan420 closed 5 months ago
Thank you for creating this issue. I'll investigate the problem.
For now, look like you can use second approach and install the eslint-plugin-powerbi-visuals
if you didn't do it before.
Hello,
I do have it installed and I got it included in .eslintrc.js
. I also made sure to have it included in .eslinrc
.
I'd like to add that my custom visual was generated using tools v5.3.0
Hello, I've resolved my problem by
.exlintrc.js
to .eslintrc.cjs
. didn't end up using .eslintrc
in the end.eslint-plugin-powerbi-visuals
and @typescript-eslint/eslint-plugin
globally. has to be the 2 of em..eslintrc.cjs
..eslintrc.cjs
is included in tsconfig.Hello, I've resolved my problem by
- Rename
.exlintrc.js
to.eslintrc.cjs
. didn't end up using.eslintrc
in the end.- Install both
eslint-plugin-powerbi-visuals
and@typescript-eslint/eslint-plugin
globally. has to be the 2 of em.- Make sure both plugins are included in
.eslintrc.cjs
.- Make sure that
.eslintrc.cjs
is included in tsconfig.
Where are the files located for 1 above? How do I install globally for 2? How for 3 and 4?
I am very new to all this stuff and I am simply trying to modify a power BI visual with a minor edit to the visual.ts file and that took me like 10 minutes and I have spent hours trying to figure out how to package the visual back up to actually test the change.
npm i -g eslint-plugin-powerbi-visuals @typescript-eslint/eslint-plugin
Hello @PlastMan420. Is it possible to share with me the source code to reproduce this issue?
Thank you for the information you provided in this topic. I was able to reproduce it and fix the issue!
The new version will be available in a few upcoming days.
using latest v 5.4.1 Running
pbiviz package
will throw this error. it complains .eslintrc.jsAnother issue is replacing .eslintc.js with .eslintrc (json config). it would throw that error instead ->
Error: Failed to load plugin 'powerbi-visuals' declared in 'CLIOptions': Cannot find module 'eslint-plugin-powerbi-visuals'
tools v5.3.0 works fine.