Skip to content
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

[pull] main from microsoft:main #43

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions .eslintignore

This file was deleted.

13 changes: 13 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,19 @@

This page contains information about changes to the PowerBI Visual Tools (pbiviz).

## 5.6.0
* Updated to ESLint v9
* Updated to TypeScript v5
* `--use-default` flag for `pbiviz package` and `pbiviz lint` commands is deprecated. Recommeded config is used by default

## 5.5.1
* Fixed subtotal feature check

## 5.5.0
* Changed path for storing certificates. It allows the certificate to be reused regardless of tools version. New path is `({home directory}/pbiviz-certs)`.
* Windows version lower 10 is deprecated.
* Resolve of symlinks is disabled.

## 5.4.3
* Fixed bug with missing plugins for Eslint.
* New flag `--use-default` for `pbiviz package` and `pbiviz lint` commands. Use this command to lint files according to recommended lint config.
Expand Down
4 changes: 1 addition & 3 deletions bin/pbiviz.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ pbiviz
pbiviz
.command('lint')
.option('--fix', 'Enable autofixing of lint errors')
.option('--use-default', 'Use recommended eslintrc file')
.action(options => {
CommandManager.lint({ ...options, verbose: true }, rootPath);
});
Expand All @@ -85,7 +84,7 @@ pbiviz
.option('--no-stats', "Doesn't generate statistics files")
.option('--skip-api', "Skips powerbi-visuals-api verifying")
.option('-l, --all-locales', "Keeps all locale files in the package. By default only used inside stringResources folder locales are included.")
.option('-p, --pbiviz-file <pbiviz-file>', "Path to pbiviz.json file (useful for debugging)", pbivizFile)
.option('-f, --pbiviz-file <pbiviz-file>', "Path to pbiviz.json file (useful for debugging)", pbivizFile)
.action(async (options) => {
CommandManager.start(options, rootPath);
});
Expand All @@ -101,7 +100,6 @@ pbiviz
.option('-l, --all-locales', "Keeps all locale files in the package. By default only used inside stringResources folder locales are included.")
.option('-v, --verbose', "Enables verbose logging")
.option('--fix', 'Enable autofixing of lint errors')
.option('--use-default', 'Use recommended eslintrc file')
.option('-p, --pbiviz-file <pbiviz-file>', "Path to pbiviz.json file (useful for debugging)", pbivizFile)
.addOption(new Option('-c, --compression <compressionLevel>', "Enables compression of visual package")
.choices(['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'])
Expand Down
8 changes: 5 additions & 3 deletions config.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,11 @@
"package": { "dropFolder": "dist" },
"server": {
"assetsRoute": "/assets",
"privateKey": "certs/PowerBICustomVisualTest_private.key",
"certificate": "certs/PowerBICustomVisualTest_public.crt",
"pfx": "certs/PowerBICustomVisualTest_public.pfx"
"certificateFolder": "pbiviz-certs",
"privateKey": "PowerBICustomVisualTest_private.key",
"certificate": "PowerBICustomVisualTest_public.crt",
"pfx": "PowerBICustomVisualTest_public.pfx",
"passphrase": "PowerBICustomVisualTestPass.txt"
},
"visualTemplates": {
"circlecard": "https://codeload.github.com/microsoft/powerbi-visuals-circlecard-react/zip/master"
Expand Down
37 changes: 37 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
import typescriptEslint from "@typescript-eslint/eslint-plugin";
import globals from "globals";
import tsParser from "@typescript-eslint/parser";

export default [
{
files: ["*.ts", "*tsx"],
ignores: [
"node_modules/",
"dist/",
"templates/",
"spec/*/**",
"**/lib/",
"bin/",
"eslint.config.mjs",
],
plugins: {
"@typescript-eslint": typescriptEslint,
},
languageOptions: {
globals: {
...globals.node,
},
parser: tsParser,
ecmaVersion: 2023,
sourceType: "module",
parserOptions: {
project: "tsconfig.json",
tsconfigRootDir: ".",
},
},
rules: {
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "error",
},
}
];
Loading