0.0.5 • Published 10 months ago

@dmno/netlify-platform v0.0.5

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

Check out the docs for more information on how to use DMNO with Netlify.

If you have any questions, please reach out to us on Discord.


@dmno/netlify-platform npm

This package provides a set of prebuilt types and environment variables for Netlify.

Installation

npm add @dmno/netlify-platform

Example Usage

import { defineDmnoService, switchBy, pickFromSchemaObject } from 'dmno';
import { NetlifyEnvSchema } from '@dmno/netlify-platform/types';

export default defineDmnoService({
  schema: {
    ...pickFromSchemaObject(NetlifyEnvSchema, 'CONTEXT', 'BUILD_ID'),
    APP_ENV: {
      value: switchBy('CONTEXT', {
        _default: 'local',
        'deploy-preview': 'staging',
        'branch-deploy': 'staging',
        production: 'production',
      }),
    },
  },
});
0.0.5

10 months ago

0.0.4

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago