Extra Block Types (EBT) - New Layout Builder experience❗

Extra Block Types (EBT) - styled, customizable block types: Slideshows, Tabs, Cards, Accordions and many others. Built-in settings for background, DOM Box, javascript plugins. Experience the future of layout building today.

Demo EBT modules Download EBT modules

❗Extra Paragraph Types (EPT) - New Paragraphs experience

Extra Paragraph Types (EPT) - analogical paragraph based set of modules.

Demo EPT modules Download EPT modules

Scroll

Running Next.js frontend example

03/04/2025, by Ivan

In folder /frontend-examples/articles-with-tags-filter you can find Next.js application which uses JsonDrop API.

Overview

This is a Next.js application that demonstrates integration with JsonDrop API for managing articles with tags and filtering functionality.

Next.js app1
Next.js app Frontpage
next.js articles
Next.js application Articles listing page.
Contact Us form
Next.js application Contact form.

Prerequisites

  • Node.js (v18 or higher)
  • npm or pnpm package manager
  • Access to a JsonDrop API instance

Installation

  1. Clone the repository
  2. Install dependencies:
    npm install
    # or
    pnpm install
  3. Configure environment variables:
    • Create a .env file in the root directory
    • Set the following variable:
      NEXT_PUBLIC_DRUPAL_BASE_URL="http://your-jsonapi-instance"

Running the Application

To start the development server:

npm run dev
# or
pnpm dev

The application will be available at http://localhost:3000

npm run dev
Running an application with Next.js

Available Routes

  • / - Home page with article list and tag filtering
  • /articles - Article listing page
  • /form - Form page for creating/editing articles

Configuration

Environment Variables

  • NEXT_PUBLIC_DRUPAL_BASE_URL - Base URL of your JsonDrop API instance

Dependencies

The application uses several key dependencies:

  • Next.js 15.1.0
  • React 19
  • Axios for API calls
  • TailwindCSS for styling
  • Radix UI components
  • React Hook Form for form handling

Common Pitfalls

API Configuration

Ensure the NEXT_PUBLIC_DRUPAL_BASE_URL environment variable is correctly set to your JsonDrop API instance. Incorrect configuration will result in failed API requests.

CORS Issues

If you encounter CORS errors, ensure your JsonDrop API instance is configured to accept requests from your development domain (localhost:3000).

Environment Variables

Remember that environment variables prefixed with NEXT_PUBLIC_ are exposed to the browser. Do not include sensitive information in these variables.

Building for Production

To create a production build:

npm run build
# or
pnpm build

To start the production server:

npm run start
# or
pnpm start

Support

For issues or questions, please refer to the project documentation or create an issue in the repository.