Getting started

    1. Setup Next.js

    Get started by creating a new Next.js project. The following will setup a project in your chosen directory. If you'd like to add Alinea to an existing project, skip this step and continue with step 2.

    npx create-next-app@latest

    Read the full instructions in the Next.js docs

    2. Install Alinea

    Navigate to the newly created project directory and install the package with your preferred package manager.

    npm install alinea

    3. Initialize the project

    Alinea requires a config file which can be auto-generated by running alinea init. If you prefer plain Javascript over Typescript, rename the created file from cms.ts to cms.js.

    npx alinea init

    4. Adjust Next.js config

    To work around a few Next.js quirks some config changes are needed. Alinea exports a function to do this for you:

    import {withAlinea} from 'alinea/next'
    
    const nextConfig = {...}
    
    export default withAlinea(nextConfig)

    5. Access the dashboard

    Congratulations, Alinea is now ready to boot!
    Have a look around in the dashboard by running:

    npx alinea dev