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

plutt

v2.0.10

Published

Safe micro frontends without the hassle

Downloads

9

Readme

Plutt: Safe micro frontends without the hassle

Version Downloads/week License

🗒 Description

Plutt is a build tool that enables developers to generate micro frontends from framework-native components and to serve them version safely. The micro frontends are automatically safe to use in production if they work during development.

✨ Features

  • Access Transparency: Consuming applications use the micro frontends as regular components, without having to know that it is a micro frontend.
  • Automatic Version Safety: At run-time Plutt will always upgrade to the latest version of a micro frontend, as long as it is non-breaking. This is done by supporting lock-step deployments.
  • Framework Agnostic: Plutt applications can be consumed by any framework. Currently Plutt supports React and Vue, but it is easy to extend Plutt to support more frameworks.
  • Type Safety: Micro frontends can be consumed with type safety. Any props that are used incorrectly can be found at compile-time.

🏗 Usage

$ npm install -g plutt
$ plutt COMMAND
running command...
$ plutt (-v|--version|version)
plutt/0.0.0-semantically-released darwin-x64 node-v13.10.1
$ plutt --help [COMMAND]
USAGE
  $ plutt COMMAND
...

📚 Examples

All examples are located at Plutt Examples Collection.

🔍 How Plutt Works

Plutt is a build tool that enables developers to generate micro frontends from framework-native components and to serve them version safely. Plutt takes a framework-native component as input and outputs two types of artifacts: a Plutt Application (composed of the original Component and a Wrapper) and a Proxy. To serve Plutt applications, Plutt provides a Plutt Server.

You can use only a Plutt Application, but to get most benefits you should use the provided Proxy and Plutt Server.

Plutt Architecture

Plutt Application

A Plutt application is a self-contained micro frontend application that exposes functions for mounting with properties, updating the properties, and unmounting. Plutt applications are stored on a Plutt server and accessed in run-time, to ensure that the latest version is consumed.

Proxy

A proxy is a framework-native component that knows how to fetch and mount a corresponding Plutt application. Plutt generates one proxy per supported framework, which currently is React and Vue. Proxies integrate into a parent application during compile-time. Proxies do not include any business logic, but they do include everything required to safely consume a Plutt application. Proxies fetch a specific version of a Plutt application which can be verified at compile-time to be non-breaking. If the Plutt application is typed, the proxy is also typed, and static analysis can be used to indicate if a Plutt application is integrated correctly.

Plutt Server

Plutt applications are stored on a Plutt server, which is where dependents fetch Plutt applications from. Plutt server upgrade requests to Plutt applications so that dependents receive the latest non-breaking version. Semantic versioning is used to ensure that the upgraded version is non-breaking. This way, the team that provides a micro frontend is responsible for deciding when to update to production, while ensuring that updates do not break dependent applications. Dependent teams own the decision of when to upgrade breaking versions. Plutt server provides every team with the correct responsibilities that facilitate independent deployments.

🔨 Commands

plutt build

Build a plutt app.

USAGE
  $ plutt build

OPTIONS
  -s, --sourceDirectory=sourceDirectory  [default: src] Source directory for the plutt app.
  -v, --verbose                          Prints extra information. Useful for debuging.

DESCRIPTION
  Build a plutt app.

  Make sure that there exists a src/ directory with an index.js.

plutt help [COMMAND]

display help for plutt

USAGE
  $ plutt help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI

See code: @oclif/plugin-help

plutt serve [DIRECTORY]

Serve a plutt app.

USAGE
  $ plutt serve [DIRECTORY]

ARGUMENTS
  DIRECTORY  [default: .] Directory to serve plutt apps from

OPTIONS
  -p, --port=port  [default: 5000] Port used to serve plutt app

🐢 Learn More

This project is developed together with a thesis, that will finish this summer. A link to the thesis will be published here when the thesis is finished.