chore: release @excalidraw/excalidraw@18.0.0 🎉 (#9127)

This commit is contained in:
Marcel Mraz 2025-02-28 16:49:09 +01:00 committed by GitHub
parent 392118bf26
commit ecef5d12f4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
232 changed files with 3412 additions and 2851 deletions

3
packages/math/global.d.ts vendored Normal file
View file

@ -0,0 +1,3 @@
/// <reference types="vite/client" />
import "@excalidraw/excalidraw/global";
import "@excalidraw/excalidraw/css";

View file

@ -1,16 +1,20 @@
{
"name": "@excalidraw/math",
"version": "0.1.0",
"main": "./dist/prod/index.js",
"type": "module",
"types": "./dist/types/math/index.d.ts",
"main": "./dist/prod/index.js",
"module": "./dist/prod/index.js",
"exports": {
".": {
"development": "./dist/dev/index.js",
"production": "./dist/prod/index.js",
"default": "./dist/prod/index.js"
},
"./*": {
"types": "./../math/dist/types/math/*"
}
},
"types": "./dist/utils/index.d.ts",
"files": [
"dist/*"
],
@ -48,14 +52,8 @@
},
"bugs": "https://github.com/excalidraw/excalidraw/issues",
"repository": "https://github.com/excalidraw/excalidraw",
"dependencies": {
"@excalidraw/utils": "*"
},
"scripts": {
"gen:types": "rm -rf types && tsc",
"build:umd": "cross-env NODE_ENV=production webpack --config webpack.prod.config.js",
"build:esm": "rm -rf dist && node ../../scripts/buildUtils.js && yarn gen:types",
"build:umd:withAnalyzer": "cross-env NODE_ENV=production ANALYZER=true webpack --config webpack.prod.config.js",
"pack": "yarn build:umd && yarn pack"
"build:esm": "rm -rf dist && node ../../scripts/buildMath.js && yarn gen:types"
}
}

View file

@ -1,4 +1,4 @@
import { toBrandedType } from "../excalidraw/utils";
import { toBrandedType } from "@excalidraw/excalidraw/utils";
import type { InclusiveRange } from "./types";
/**

View file

@ -0,0 +1,24 @@
{
"compilerOptions": {
"outDir": "./dist/types",
"target": "ESNext",
"strict": true,
"skipLibCheck": true,
"declaration": true,
"allowSyntheticDefaultImports": true,
"module": "ESNext",
"moduleResolution": "Node",
"resolveJsonModule": true,
"jsx": "react-jsx",
"emitDeclarationOnly": true,
"paths": {
"@excalidraw/excalidraw": ["../excalidraw/index.tsx"],
"@excalidraw/utils": ["../utils/index.ts"],
"@excalidraw/math": ["../math/index.ts"],
"@excalidraw/excalidraw/*": ["../excalidraw/*"],
"@excalidraw/utils/*": ["../utils/*"],
"@excalidraw/math/*": ["../math/*"]
}
},
"exclude": ["**/*.test.*", "tests", "types", "examples", "dist"]
}

View file

@ -1,55 +0,0 @@
const webpack = require("webpack");
const path = require("path");
const BundleAnalyzerPlugin =
require("webpack-bundle-analyzer").BundleAnalyzerPlugin;
module.exports = {
mode: "production",
entry: { "excalidraw-math.min": "./index.js" },
output: {
path: path.resolve(__dirname, "dist"),
filename: "[name].js",
library: "ExcalidrawMath",
libraryTarget: "umd",
},
resolve: {
extensions: [".tsx", ".ts", ".js", ".css", ".scss"],
},
optimization: {
runtimeChunk: false,
},
module: {
rules: [
{
test: /\.(ts|tsx|js)$/,
use: [
{
loader: "ts-loader",
options: {
transpileOnly: true,
configFile: path.resolve(__dirname, "../tsconfig.prod.json"),
},
},
{
loader: "babel-loader",
options: {
presets: [
"@babel/preset-env",
["@babel/preset-react", { runtime: "automatic" }],
"@babel/preset-typescript",
],
plugins: [["@babel/plugin-transform-runtime"]],
},
},
],
},
],
},
plugins: [
new webpack.optimize.LimitChunkCountPlugin({
maxChunks: 1,
}),
...(process.env.ANALYZER === "true" ? [new BundleAnalyzerPlugin()] : []),
],
};