Unverified Commit e3370c56 authored by Raoul v. R's avatar Raoul v. R Committed by GitHub
Browse files

Merge pull request #502 from pmndrs/dev

Version 6.32.0
parents a368e9d7 99cda7c4
Showing with 201 additions and 208 deletions
+201 -208
......@@ -19,10 +19,10 @@ const banner = `/**
*/`;
const workers = {
entryPoints: await glob("src/**/worker.js"),
entryPoints: await glob("./src/**/worker.js"),
outExtension: { ".js": ".txt" },
outdir: "tmp",
target: "es6",
outdir: "./tmp",
target: "es2019",
logLevel: "info",
format: "iife",
bundle: true,
......@@ -30,8 +30,8 @@ const workers = {
};
const demo = {
entryPoints: ["demo/src/index.js"],
outdir: "public/demo",
entryPoints: ["./demo/src/index.js"],
outdir: "./public/demo",
target: "es6",
logLevel: "info",
format: "iife",
......@@ -41,9 +41,9 @@ const demo = {
};
const manual = {
entryPoints: ["manual/assets/js/src/index.js"]
.concat(await glob("manual/assets/js/src/demos/*.js")),
outdir: "manual/assets/js/dist",
entryPoints: ["./manual/assets/js/src/index.js"]
.concat(await glob("./manual/assets/js/src/demos/*.js")),
outdir: "./manual/assets/js/dist",
logLevel: "info",
format: "iife",
target: "es6",
......@@ -54,8 +54,8 @@ const manual = {
};
await esbuild.build({
entryPoints: ["manual/assets/js/libs/vendor.js"],
outdir: "manual/assets/js/dist/libs",
entryPoints: ["./manual/assets/js/libs/vendor.js"],
outdir: "./manual/assets/js/dist/libs",
globalName: "VENDOR",
target: "es6",
logLevel: "info",
......@@ -82,8 +82,8 @@ if(process.argv.includes("-w")) {
}
await esbuild.build({
entryPoints: ["src/index.js"],
outfile: `build/${pkg.name}.esm.js`,
entryPoints: ["./src/index.js"],
outfile: "./build/index.js",
banner: { js: banner },
logLevel: "info",
format: "esm",
......@@ -93,31 +93,32 @@ await esbuild.build({
plugins
});
// @todo Remove in next major release.
await esbuild.build({
entryPoints: ["src/index.js"],
outfile: `build/${pkg.name}.mjs`,
entryPoints: ["./src/index.js"],
outfile: "./build/index.cjs",
banner: { js: banner },
logLevel: "info",
format: "esm",
format: "cjs",
target: "es2019",
bundle: true,
external,
plugins
});
// @todo Remove in next major release.
const globalName = pkg.name.replace(/-/g, "").toUpperCase();
const requireShim = "if(typeof window===\"object\"&&!window.require)window.require=()=>window.THREE;";
const footer = `if(typeof module==="object"&&module.exports)module.exports=${globalName};`;
await esbuild.build({
entryPoints: ["src/index.js"],
outfile: `build/${pkg.name}.js`,
entryPoints: ["./src/index.js"],
outfile: `./build/${pkg.name}.js`,
banner: { js: `${banner}\n${requireShim}` },
footer: { js: footer },
logLevel: "info",
format: "iife",
target: "es6",
target: "es2019",
bundle: true,
globalName,
external,
......@@ -125,13 +126,13 @@ await esbuild.build({
});
await esbuild.build({
entryPoints: ["src/index.js"],
outfile: `build/${pkg.name}.min.js`,
entryPoints: ["./src/index.js"],
outfile: `./build/${pkg.name}.min.js`,
banner: { js: `${banner}\n${requireShim}` },
footer: { js: footer },
logLevel: "info",
format: "iife",
target: "es6",
target: "es2019",
bundle: true,
globalName,
external,
......
{
"name": "postprocessing",
"version": "6.31.2",
"description": "A post processing library that provides the means to implement image filter effects for three.js.",
"version": "6.32.0",
"description": "A post processing library for three.js.",
"homepage": "https://github.com/pmndrs/postprocessing",
"sideEffects": false,
"license": "Zlib",
"main": "build/postprocessing.js",
"module": "build/postprocessing.esm.js",
"types": "types/postprocessing.d.ts",
"type": "module",
"sideEffects": false,
"main": "./build/index.cjs",
"module": "./build/index.js",
"types": "./types/index.d.ts",
"exports": {
".": {
"types": "./types/postprocessing.d.ts",
"import": "./build/postprocessing.esm.js",
"require": "./build/postprocessing.js"
},
"./module": {
"types": "./types/postprocessing.d.ts",
"import": "./build/postprocessing.mjs"
"types": "./types/index.d.ts",
"import": "./build/index.js",
"require": "./build/index.cjs"
}
},
"keywords": [
......@@ -46,8 +43,8 @@
"url": "https://github.com/pmndrs/postprocessing/issues"
},
"files": [
"build",
"types"
"./build",
"./types"
],
"engines": {
"node": ">= 0.13.2"
......@@ -55,8 +52,8 @@
"scripts": {
"ava": "ava",
"build:css": "sass --no-source-map -I manual/assets/css/src/values manual/assets/css/src:manual/assets/css/dist",
"build:js": "node esbuild.mjs",
"build:js:min": "node esbuild.mjs -m",
"build:js": "node esbuild",
"build:js:min": "node esbuild -m",
"clean": "del-cli build tmp manual/resources manual/assets/**/dist public",
"copy": "copyfiles -u 2 \"demo/static/**/*\" public/demo",
"deploy": "run-s copy postcss hugo gzip",
......@@ -74,12 +71,12 @@
"watch": "run-p watch:* start",
"watch:css": "sass --no-source-map -I manual/assets/css/src/values manual/assets/css/src:manual/assets/css/dist -w",
"watch:eslint": "esw -w --ext .js --color src demo/src manual/assets/js/src",
"watch:js": "node esbuild.mjs -w"
"watch:js": "node esbuild -w"
},
"ava": {
"failFast": true,
"files": [
"test/**/*"
"./test/**/*"
]
},
"eslintConfig": {
......
This diff is collapsed.
import test from "ava";
import { EffectComposer } from "postprocessing/module";
import { EffectComposer } from "postprocessing";
test("can be instantiated and disposed", t => {
......
import test from "ava";
import { GaussKernel } from "postprocessing/module";
import { GaussKernel } from "postprocessing";
test("can be instantiated", t => {
......
import test from "ava";
import { OverrideMaterialManager } from "postprocessing/module";
import { OverrideMaterialManager } from "postprocessing";
test("can be instantiated and disposed", t => {
......
import test from "ava";
import { Resolution } from "postprocessing/module";
import { Resolution } from "postprocessing";
test("can be instantiated", t => {
......
import test from "ava";
import { Selection } from "postprocessing/module";
import { Selection } from "postprocessing";
test("can be instantiated", t => {
......
import test from "ava";
import { Timer } from "postprocessing/module";
import { Timer } from "postprocessing";
const SECONDS_TO_MILLISECONDS = 1e3;
......
import test from "ava";
import { BloomEffect } from "postprocessing/module";
import { BloomEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { BokehEffect } from "postprocessing/module";
import { BokehEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { BrightnessContrastEffect } from "postprocessing/module";
import { BrightnessContrastEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { ChromaticAberrationEffect } from "postprocessing/module";
import { ChromaticAberrationEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { ColorAverageEffect } from "postprocessing/module";
import { ColorAverageEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { ColorDepthEffect } from "postprocessing/module";
import { ColorDepthEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { DepthEffect } from "postprocessing/module";
import { DepthEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { DepthOfFieldEffect } from "postprocessing/module";
import { DepthOfFieldEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { DotScreenEffect } from "postprocessing/module";
import { DotScreenEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { Effect } from "postprocessing/module";
import { Effect } from "postprocessing";
test("can be created and destroyed", t => {
......
import test from "ava";
import { FXAAEffect } from "postprocessing/module";
import { FXAAEffect } from "postprocessing";
test("can be created and destroyed", t => {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment