32.9 GB
31,201 files
Updated 2 months ago
Name
Size
styles
public
pages
lib
components
tsconfig.json653 Bytes
xet
tailwind.config.js968 Bytes
xet
postcss.config.js204 Bytes
xet
package.json548 Bytes
xet
next.config.js323 Bytes
xet
README.md3.2 kB
xet
.gitignore437 Bytes
xet
.env.local.example81 Bytes
xet
README.md

A statically generated blog example using Next.js and dotCMS

This example showcases Next.js's Static Generation feature using dotCMS as the data source.

Demo

https://nextjs-dotcms-blog.vercel.app/

Deploy your own

Using the Deploy Button below, you'll deploy the Next.js project.

Deploy with Vercel

Related examples

How to use

Rename .env.local.example to .env.local and complete the variables:

NEXT_PUBLIC_DOTCMS_HOST is the dotCMS host, you can use https://demo.dotcms.com DOTCMS_TOKEN for the demo site, you can generate the token using:

curl -H "Content-Type:application/json" --insecure  -X POST -d  '
{ "user":"admin@dotcms.com", "password":"admin", "expirationDays": 10 }
' http://demo.dotcms.com:8080/api/v1/authentication/api-token

Execute create-next-app with npm, Yarn, or pnpm to bootstrap the example:

npx create-next-app --example cms-dotcms cms-dotcms-app
yarn create next-app --example cms-dotcms cms-dotcms-app
pnpm create next-app --example cms-dotcms cms-dotcms-app

Deploy with Vercel

Total size
32.9 GB
Files
31,201
Last updated
Sep 26
Pre-warmed CDN
US EU US EU

Contributors