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

teams-angular

v0.4.0

Published

Angular schematics to create Microsoft Teams applications.

Downloads

17

Readme

👥 teams-angular

NPM version Build Status Node version License

Angular schematics to create Microsoft Teams applications.

Usage

ng new

This package provides a schematic that creates a new Angular app configured to be deployed as a Microsoft Teams app. The generated app includes:

  • authentication configuration using Microsoft Identity Platform,
  • Single-Sign On (SSO) configuration with Microsoft Teams,
  • additional npm scripts to create Azure AD application and manage the Teams app package

To use this schematic, make sure you have @angular/cli installed and run:

npm install -g teams-angular
ng new teams-app --collection teams-angular

Note: if you get an error like An unhandled exception occurred: Collection "teams-angular" cannot be resolved., it may be related to your NPM installation. Here are a few commands that you can try to fix the issue:

npm uninstall -g @angular/cli teams-angular
npm cache clean --force
npm install -g npm@latest
npm install -g @angular/cli teams-angular

Deploying to production

When you are ready to deploy your app to production, there are two main steps needed to make your app available to the public: first you need to deploy your web app on a server, and then you need to publish the app to your production tenant.

Step 1: Deploying your web app

  1. Build app for production in dist/ folder using npm run build.
  2. Deploy the built app to your favorite cloud provider. See instructions below for deploying to Azure Static Web Apps for example.

Step 2: Deploying your Teams app

  1. Set your production URL with node scripts/update-manifest.js <production_url>
  2. Login to CLI for Microsoft 365 onto the production tenant: npm run m365:login
  3. Create the Azure Active Directory (AAD) app: npm run m365:create-aad-app
  4. Publish app to Teams: npm run m365:publish

Deploying web app to to Azure Static Web Apps

What's Azure Static Web Apps? It's an all-inclusive hosting service for web apps providing features like continuous deployment, serverless APIs, authentication and more. And it has a free tier!

Prerequisites:

  1. Click on this button to open the Azure portal: Deploy to Azure button
  2. Fill in the details (you don't need to change what's not mentioned):
  • Resource Group: Select Create new and type in angular-teams-app
  • Name: Type in angular-teams-app
  • Select Sign in with GitHub, and pick the Organization, Repository and Branch for the repo with the app you want to deploy.
  1. Select Review + Create, then Create.

Wait a few seconds for everything to be set up, and click on Go to resource. From there, you'll be able to see the new public URL that was created for your app in the URL field.

This is what you'll use for your production URL. After a few minutes, your Teams app will be available at this URL.

You can find more tutorials on using Static Web Apps here.

Contributing

To test locally, run npm test:schematics. This will act the same as the generate command of the Angular CLI, but using a debug mode.

npm run test will run the unit tests, using Jest as a runner and test framework.