GithubHelp home page GithubHelp logo

pascal-codetaal / starter-express Goto Github PK

View Code? Open in Web Editor NEW

This project forked from remix-run/starter-express

0.0 0.0 0.0 305 KB

Starter project for using Remix with Express

Home Page: https://remix.run

JavaScript 30.95% CSS 5.09% TypeScript 63.95%

starter-express's Introduction

Remix Starter for Express

Welcome to Remix!

This is a starter repo for using Remix with Express.

Development

After cloning the repo, rename .npmrc.example to .npmrc and insert the license key you get from logging in to your dashboard at remix.run.

Note: if this is a public repo, you'll probably want to move the line with your key into ~/.npmrc to keep it private.

Then, install all dependencies using npm:

$ npm install

Your @remix-run/* dependencies will come from the Remix package registry.

Once everything is installed, start the app in development mode with the following command:

$ npm run dev

This will run a few processes concurrently that will dynamically rebuild as your source files change. To see your changes, refresh the browser.

Note: Hot module reloading is coming soon, which will allow you to see your changes without refreshing.

Production

To run the app in production mode, you'll need to build it first.

$ npm run build
$ npm start

This will start a single HTTP server process that will serve the app from the files generated in the build step.

Documentation

Detailed documentation for Remix is available at remix.run.

Project Structure

There are 2 main directories you will want to be familiar with: app and loaders.

  • The app directory contains the major pieces that make up the frontend of your application. These include the entry points, routes, and CSS files. Most of the code in this directory runs both on the server and in the browser.
  • The loaders directory contains functions that supply data to the frontend. These functions run only in node.js.

Remix is responsible for compiling everything in your app directory so that it can run both on the server (to render the HTML needed for the page, aka server-side rendering or "SSR") and in the browser. It's your responsibility to compile the code in loaders, if needed.

This project uses TypeScript for type safety. There are two main TypeScript configs in app/tsconfig.json and loaders/tsconfig.json. The tsconfig.json in the project root is a "solution" file that just contains references to the other two configs.

Don't want TypeScript?

The no-typescript branch is a version of this same starter template that uses plain JavaScript instead of TypeScript for all code in app and loaders.

starter-express's People

Contributors

cdock1029 avatar flexbox avatar mjackson avatar pascal-codetaal avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.