Skip to content

Quick Start

Aniket Prajapati edited this page Dec 28, 2020 · 8 revisions

You can find the src for this website here

Create a new project with yarn init or npm init

Install

install FireJSX using yarn or npm

yarn

$ yarn add firejsx react react-dom

npm

$ npm install firejsx react react-dom

Make A Page

Make dirs src/pages in the project root. This dir will contain all the pages required for our brand-new website.

Make a file index.jsx in that dir. This file will be the home page of our website.

export default function() {
  return (
    <div>
        <h1>My first FireJSX web page</h1>
    </div>  
  )
}

Add the following script(s) to package.json

"scripts": {
    "dev": "firejsx"
}

Now run using yarn or npm

yarn

$ yarn run dev

npm

$ npm run dev

Navigate to URL logged into the terminal and there it says My first FireJSX web page.

From now we will use yarn as our default package manager

Clone this wiki locally