Some test text!

Search
Hamburger Icon

Nodejs / FAQ / I am encountering errors running PDFNet-Node with next.js 13 and up

I am encountering errors running PDFNet-Node with next.js 13 via NPM

In order to use our NPM package for Node.js with Next.js 13 and up an alteration has to be made in the Next.js configuration in your next.config

/** @type {import('next').NextConfig} */
const nextConfig = {
  webpack: (config) => {
    config.externals = [...config.externals, '@pdftron/pdfnet-node'];
    return config;
  }
}

module.exports = nextConfig

This will ensure Next.js loads the binary packages inside of the NPM package. For more info refer to the next.js documentation.

Trial setup questions? Ask experts on Discord
Need other help? Contact Support
Pricing or product questions? Contact Sales