1.0.12 • Published 11 months ago

@defaultuploader/nextjs-loader v1.0.12

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months ago

NextJS image loader by Default Uploader

Installation

You can use any package manager

npm i @defaultuploader/nextjs-loader

A client token is required to work, you can get it at this address https://admin.defaultuploader.com/admin

Documentation for the Default Uploader service is located at this address https://docs.defaultuploader.com

Setup your App

In your NextJS application, add the following rule to the config file

// next.config.mjs

const nextConfig = {
    images: {
        loader: 'custom',
        loaderFile: './src/lib/default-uploader.ts',
    },
};

export default nextConfig;

Next, export the loader function to the specified path (you can specify any path)

// src/lib/default-uploader.ts
import defaultUploader from '@default-uploader/nextjs'

export default defaultUploader(DEFAULT_UPLOADER_CLIENT_TOKEN)

That's all. Now you have a powerful API for file transformation, and you are not tied to any vendor =)

1.0.12

11 months ago

1.0.11

11 months ago

1.0.10

11 months ago

1.0.9

11 months ago

1.0.8

11 months ago

1.0.7

11 months ago

1.0.6

11 months ago

1.0.5

11 months ago

1.0.4

11 months ago

1.0.3

11 months ago