github.com/simpleiot/simpleiot@v0.18.3/frontend/README.md (about)

     1  # new elm-spa project
     2  > More documentation at https://elm-spa.dev
     3  
     4  ## local development
     5  
     6  You can get this site up and running with one command:
     7  
     8  ```
     9  npm start
    10  ```
    11  
    12  ### other commands to know
    13  
    14  There are a handful of commands in the [package.json](./package.json).
    15  
    16  Command | Description
    17  :-- | :--
    18  `npm run dev` | Run a dev server and automatically build changes.
    19  `npm run test:watch` | Run tests as you code.
    20  `npm run build` | Build the site for production.
    21  `npm run test` | Run the test suite once, great for CI
    22  
    23  
    24  ## deploying
    25  
    26  After you run `npm run build`, the contents of the `public` folder can be hosted as a static site. If you haven't hosted a static site before, I'd recommend using [Netlify](https://netlify.com) (it's free!)
    27  
    28  ### using netlify
    29  
    30  Add a `netlify.toml` file next to this README, for standard SPA routing:
    31  
    32  ```toml
    33  [[redirects]]
    34    from = "/*"
    35    to = "/index.html"
    36    status = 200
    37  ```
    38   
    39  __Build command:__ `npm run build`
    40  
    41  __Publish directory:__ `public`