Skip to content

Basic preact frontend site for the paste-server instance

License

Notifications You must be signed in to change notification settings

h5law/paste-site

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

57 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

paste-site

This is a simple Preact frontend for the paste-server

Install

This requires Node v16.16.0+

To install simply clone this repo and install the npm dependencies:

git clone https://github.com/h5law/paste-site
cd paste-site
npm i

Then to run in a non production environment do either: NODE_ENV="development" npm run dev or NODE_ENV="development" npm run serve

It is needed to use the NODE_ENV before the command so that the SPA looks for the paste-server instance running locally on 127.0.0.1:3000 for the API calls as otherwise the SPA will assume this is being served through the paste-server instance it is made for, and will use the window.location.origin value for making API calls which wont work unless the paste-instance server is both running AND on the same port.

Build

To build this yourself simply run:

npm run build

And have your paste-server instance point to the build directory when starting it using the --spa-dir flag:

paste-server start -v --spa-dir="./build"

TODO

  • Make look and feel better
  • Add syntax highlighting with highlight.js

About

Basic preact frontend site for the paste-server instance

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published