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

vussr

v4.5.2

Published

✊ VUSSR—Server Side Rendering for VUE

Downloads

16

Readme

vuedssr logo

✊ VUSSR

Development and Production Server Side Renderer for VUE

About

VUSSR provides you with a Webpack DevServer for development and an Express Server for production to render your VUE application on the server and hydrate it on the client. It comes with a command line API to run your app

Quick Start

  1. Install VUSSR
  2. Add src/entry.client.js and src/entry.server.js
  3. Add npm scripts
  4. Run npm run serve

Install VUSSR

npm i vussr --save # yarn add vussr

Create Entry Points

By default, VUSSR looks for 2 files as entry points, one for your client and one for your server:

root
 ∟ src
    ∟ entry.client.js
    ∟ entry.server.js

entry.server.js is the base file for your server. This file has to have a function as default export that returns an instance of your Vue app.

entry.client.js is the base file for your client code. Any code that will be sent to and executed in the client needs to be included or imported in the in this file. Usually, you will want to import and mount your the same app that you used in your server entrypoint.

👉 Please refer to this example app for a very basic setup

Add npm Scripts

{
  "scripts": {
    "serve": "vussr serve",
    "build": "vussr build",
    "start": "vussr start"
  }
}

Develop Your App

npm run serve

Simply run npm run serve to start your app on a development server (Webpack DevServer). It will automatically recompile your code on file changes and serve them on http://127.0.0.1:8080. You can configure the port and other Webpack DevServer related options. See Configuration.

Create a Production Build

npm run build

To run your app in production you need to create a production build and then start your production server with it. To create a production build run npm run build.

Run the Produciton Server

npm run start

Once you have created your production build your can start your production server with npm run start.

Further steps

Read more on:

Maintainers