New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

narajs

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

narajs

Folder-based react router.

unpublished
beta
latest
Source
npmnpm
Version
0.1.0-beta.0
Version published
Maintainers
1
Created
Source

Nara JS

Create React APPs with Folder-based router.

Documentation

Find all narajs documentation here

Installation

npm install narajs

Quick start

  • Initialize an NPM project.

  • Install dependencies.

# Using JavaScript
npm install narajs react react-dom

# Using TypeScript
npm install narajs react react-dom
npm install -D @types/react @types/react-dom
  • In your project create a pages folder.

  • Inside create a file page.jsx or page.tsx.

export default function Home() {
	return <h1>Hello world from Nara Js</h1>
}
  • In the root of the project create a file nara.config.js.
/** @type {import("narajs").Config} */
module.exports = {
	tsx: false // or true to enable typescript.
	routes: [
		{
			basePath: '/',
			src: 'pages',
		},
	],
}
  • In the root of the project create a file index.html.
<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="UTF-8" />
		<meta name="viewport" content="width=device-width, initial-scale=1.0" />
		<title>Nara JS</title>
	</head>
	<body>
		<div id="root"></div>
	</body>
</html>
  • Add the necessary scripts to your package.json.
{
	"scripts": {
		"start": "nara",
		"build": "nara build",
		"serve": "nara serve"
	}
}
  • Initialize the application with npm start.
npm start

FAQs

Package last updated on 12 Sep 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts