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 🙏

© 2026 – Pkg Stats / Ryan Hefner

xrmfastdev

v0.1.0

Published

WebSocket proxy server for Power Apps local development - bridges to Chrome via CDP

Readme

xrmfastdev

WebSocket proxy server for Power Apps local development. It bridges requests from xrmfastdev-client's ProxyXrmAdapter to a real, logged-in Chrome session via the Chrome DevTools Protocol — so your localhost app talks to live Dataverse with no CORS issues and no mocking.

Part of XRM Fast Dev.

Install

npm install --save-dev xrmfastdev

Ships a xrmfastdev-proxy bin, so you can also run it with npx xrmfastdev-proxy.

Usage

1. Start Chrome with remote debugging

chrome.exe --remote-debugging-port=9222 \
  --user-data-dir="%USERPROFILE%\XrmDevProfile" \
  https://your-org.crm.dynamics.com

Log in to your Model-Driven App or Power Pages portal in that window.

2. Start the proxy

npx xrmfastdev-proxy --verbose

Expected output:

=== XRM Fast Dev - Proxy Server ===

Configuration:
  Chrome CDP Port: 9222
  WebSocket Port:  8080
  Verbose:         true

[CDP] Connecting to Chrome at http://localhost:9222...
[CDP] Connected to Chrome browser
[CDP] Found Power Apps tab: https://your-org.crm.dynamics.com/...
[CDP] Detected page type: model-driven

✓ Proxy server is ready!
  Clients can connect to: ws://localhost:8080

CLI options

Usage: xrmfastdev-proxy [options]

  --cdp-port <port>   Chrome DevTools Protocol port (default: 9222)
  --ws-port <port>    WebSocket server port (default: 8080)
  --verbose, -v       Enable verbose logging
  --help, -h          Show this help message

Programmatic usage

import { CdpClient, WebSocketServer } from 'xrmfastdev';

const cdpClient = new CdpClient({ cdpPort: 9222, verbose: true });
await cdpClient.connect();

const wsServer = new WebSocketServer(cdpClient, { port: 8080, verbose: true });
wsServer.start();

process.on('SIGINT', async () => {
  wsServer.stop();
  await cdpClient.disconnect();
  process.exit(0);
});

How it works

The proxy auto-detects the page type of the connected Chrome tab:

  • Model-Driven App (window.Xrm.WebApi present) — calls Xrm.WebApi[method](...) directly.
  • Power Pages Portal (window.webapi present) — issues fetch('/_api/...') requests, automatically attaching the __RequestVerificationToken for POST/PATCH/PUT/DELETE.

Each WebSocket request { id, method, args } is executed in the browser via page.evaluate() and answered with { id, success, result | error }.

Requirements

  • Node.js >= 18
  • Google Chrome / Chromium started with --remote-debugging-port
  • Runtime dependencies: puppeteer-core, ws

Troubleshooting

| Symptom | Fix | |---------|-----| | ECONNREFUSED on 9222 | Chrome isn't running with --remote-debugging-port=9222; use a separate --user-data-dir. | | "No Power Apps tab found" | Navigate to a Model-Driven App or portal page and log in, then retry. | | Portal mutations return 401/403 | The anti-forgery token wasn't found — refresh the portal page so the hidden __RequestVerificationToken input is present. |

License

MIT © Albert Halchanskyi