
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
powerbi-models
Advanced tools
Contains JavaScript & TypeScript object models for Microsoft Power BI JavaScript SDK. For each model there is a TypeScript interface, a json schema definitions, and a validation function to ensure and object is valid.
Contains JavaScript & TypeScript object models for Microsoft Power BI JavaScript SDK.
For each model there is a TypeScript interface, a json schema definitions, and a validation function to ensure a given object is a valid model.
Install
npm install --save powerbi-models
Import
import * as models from 'powerbi-models';
Usage
Validation:
let testObject = { x: 1 };
const errors = models.validateLoad(testObject);
if(errors) {
console.warn(errors);
}
Would output to the console:
[
{
message: 'accessToken is required'
}
]
Creating filters:
const basicFilter: models.IBasicFilter = {
target: {
table: "Products",
column: "Version"
},
operator: "In",
values: [
1,
2,
3,
4
]
};
const advancedFilter: models.IAdvancedFilter = {
target: {
table: "Products",
column: "Name"
},
logicalOperator: "Or",
conditions: [
{
operator: "Contains",
value: "Power"
},
{
operator: "Contains",
value: "Microsoft"
}
]
};
Or use the constructor methods:
const advancedFilter = new models.AdvancedFilter(
{
table: "Products",
column: "Name"
},
"Or",
{
operator: "Contains",
value: "Power"
},
{
operator: "Contains",
value: "Microsoft"
}
);
FAQs
Contains JavaScript & TypeScript object models for Microsoft Power BI JavaScript SDK. For each model there is a TypeScript interface, and a validation function to ensure and object is valid.
The npm package powerbi-models receives a total of 173,593 weekly downloads. As such, powerbi-models popularity was classified as popular.
We found that powerbi-models demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.