@cran/bin.reduce

Cranberry Build System

Usage no npm install needed!

<script type="module">
  import cranBinReduce from 'https://cdn.skypack.dev/@cran/bin.reduce';
</script>

README

Cranberry Build System

CC BY-ND 4.0

Usage

[DEBUG] reduce

Configuration

interface PackageJson {
  title?: string; // falls back to name
  pm?: string; // usually npm, pnpm, yarn
  scripts?: {
    config?: string;
  };
  build?: {
    out?: string;
    src?: string;
    test?: string;
    target?:
      | "async-node" | "node" | "node-webkit"
      | "web" | "webworker";
  };
  // https://developer.mozilla.org/en-US/docs/Web/Manifest
  manifest?: Manifest;
  gtm?: {
    id: string;
    development: {
      auth: string;
      preview: string;
    },
    production: {
      auth: string;
      preview: string;
    }
  }
}

const defaults: PackageJson = {
  pm: "npm",
  build: {
    target: "web",
    out: "out",
    src: "src",
  },
  manifest: {
    background_color: "white",
    dir: "ltr",
    display: "fullscreen",
    lang: "en-US",
    orientation: "portrait-primary"
  },
}