When you use the nijor create {appname} command, it creates a new directory named after your project. This page is intended to help you understand the use of each of these directories and files.
The app directory contains the index.html file for our website. It also contains another directory called assets which stores our css file and it also contains another directory called modules which contains the js files produced by the compiler.
The src directory is our main working directory. We generally don't need to touch the app directory.
This directory stores all the reusable Nijor components.
This directory stores all the Nijor components which are to be used as pages during routing. Pages are just normal Nijor components which are used for routing, they behave normally as other Nijor components.
This directory stores our global stylesheets.
This directory stores our images which can be imported into a Nijor component just like a Javascript file using ES6 imports.
This file is the main entrypoint of our Nijor project.
This file is like the index.html for Nijor. We still need to use the index.html file sometimes though. The template tag of App.nijor is like the body of the index.html file.
The nijor.config.json
is a file which contains certain configurations for a Nijor project.
If you try to run the nijor build
,nijor compile
,nijor serve
commands inside a Nijor project without this file, then the nijor-compiler
won't work and will throw errors.