npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

powerbi-ng2

v0.2.1

Published

Angular2 components for enumerating, rendering and interacting with reports hosted in an Azure PowerBI Embed workspace.

Downloads

78

Readme

npm version powerbi-ng2 All Contributors

Overview

Angular components for enumerating, rendering and interacting with reports hosted in an Azure PowerBI Embed workspace. This package will work with both ng2 and ng4.

Install

Install via npm:

    npm install --save powerbi-ng2

Use

Import the module into your main module (generally app.module.ts):

    import { PowerBIModule, ReportsListServiceConfig } from 'powerbi-ng2';

    let _reportsListAPIEndPoint: string = "end point of your reports list Web API enumerating the reports and providing accesss tokens";

    const config:ReportsListServiceConfig = {
        WebAPIServiceUrl: 'end point of your reports list Web API enumerating the reports and providing accesss tokens'
    };

    @NgModule({
        bootstrap: [ ... ],
        declarations: [
            ...
        ],
        imports: [
            PowerBIModule.forRoot(config)
            ...
        ]
    })

Note: This module depends on the Microsoft PowerBIEmbed Javascript API. Version 2.3.2 and 2.3.3 introduced naming based incompatibilities See Issue #225. Therefore, the module requires 2.3.4 or higher as a dependency.

Note: If you use this module in conjunction with Universal (ng2), make sure to include PowerBIModule before UniversalModule as there is a conflict between the standard ng http module imported by it and the ony used by Universal. See [https://github.com/angular/universal-starter/issues/167] and [https://github.com/angular/universal/issues/536#issuecomment-247762794] for more information.

Use the various components inside your angular components. Use the ReportsListService to get a list of available reports from your workspace for navigation purposes and to get embed tokens for a particular report (alternatives, you can use the ReportsList component for that purpose).

Note that the components depend on a service endpoint (_reportsListAPIEndPoint above) for enumreation of reports and token generation. See Sample Report Service for a sample implementation of such a service using .NET Web Api 2.0.

Advanced

Check out the Wiki for detailed documentation on components, models and providers.