3.1.4 • Published 3 years ago

@bitkidd/adonis-imgix v3.1.4

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

Adonis Imgix

adonis, imgix

npm-image license-image typescript-image

An Imgix provider for Adonis 5.x

Installation

You may install this package via:

npm i @bitkidd/adonis-imgix
# or
yarn add @bitkidd/adonis-imgix

After installation you have to configure it:

node ace configure @bitkidd/adonis-imgix

This will create /config/imgix.ts file where you can configure the provider.

This package depends on one main ENV variable, IMGIX_DOMAIN, please add it to your env.ts file and actual .env file.

Usage

To use IMgix provider you should call it via import

import Imgix from '@ioc:Adonis/Addons/Imgix'

const url = Imgix.buildUrl('/test.jpg')

To properly configure the provider, follow the docs here: @imgix/core-js