Directory Structure

Nextein follows Next directory structure. As an overview, these are the relevant files and folders on a Nextein project:

├── pages
│   ├── index.js
│   └── post.js
├── posts
│   └──
├── static
│   └── hello.png
├── .babelrc
├── next.config.js
└── package.json
/pages folder

The /pages folder contains all Page Components. These components will be used as either the page that list a set of posts or render a single post.


index.js, post.js, about.js, contact.js

/posts folder

Stores all posts in markdown format. There is no need for an specific name convention. You can use whatever you want. In case you decide to use a date prefix it will be used and removed from the name property.


/static folder

The static folder serves as a repository for any static content such as images, css, videos, etc.


image.png, custom.css

.babelrc hidden file

This file is used by Next to define customized configuration for babel. This is optional.

next.config.js js file

The config file for Next. It is mandatory and it should be defined with the Nextein config wrapper.


const { default: config } = require('nextein/config')

module.exports = config({
  // place your next config in here!
package.json json file

This file is generated by npm. It will define the scripts to run nextein binaries for development, build and export among others.


  "scripts": {
    "dev": "nextein",
    "export": "nextein build && nextein export"