iceshrimp-161sh/package.json
s1idewhist1e 981d3ee725 Refactor: use rust for native mastodon id conversion (#9786)
This uses [napi-rs](https://napi.rs/) to allow for automatic generation of node bindings for the native code.

I also changed the `isolatedModules` TS flag to false to allow for `static enum` to be shared across modules. It doesn't seem to be necessary for the build system that CK uses.

Currently this method does not work with ID generators with longer IDs. Likely the best solution is to add another key in the database.

Some benchmarks for 1 million conversions:

```
	node, x1_000_000: 2.847s
	rust, x1_000_000: 1.265s
```

There are still optimizations that can be made, but I think this is a good starting point and a good way to bring rust into the CK stack.

Co-authored-by: s1idewhist1e <trombonedude05@gmail.com>
Reviewed-on: https://codeberg.org/calckey/calckey/pulls/9786
Co-authored-by: s1idewhist1e <s1idewhist1e@noreply.codeberg.org>
Co-committed-by: s1idewhist1e <s1idewhist1e@noreply.codeberg.org>
2023-03-31 01:58:28 +00:00

63 lines
1.9 KiB
JSON

{
"name": "calckey",
"version": "13.2.0-dev17",
"codename": "aqua",
"repository": {
"type": "git",
"url": "https://codeberg.org/calckey/calckey.git"
},
"packageManager": "pnpm@8.1.0",
"private": true,
"scripts": {
"rebuild": "pnpm run clean && pnpm -r run build && pnpm run gulp",
"build": "pnpm -r run build && pnpm run gulp",
"start": "pnpm --filter backend run start",
"start:test": "pnpm --filter backend run start:test",
"init": "pnpm run migrate",
"migrate": "pnpm --filter backend run migrate",
"revertmigration": "pnpm --filter backend run revertmigration",
"migrateandstart": "pnpm run migrate && pnpm run start",
"gulp": "gulp build",
"watch": "pnpm run dev",
"dev": "pnpm node ./scripts/dev.js",
"dev:staging": "NODE_OPTIONS=--max_old_space_size=3072 NODE_ENV=development pnpm run build && pnpm run start",
"lint": "pnpm -r run lint",
"cy:open": "cypress open --browser --e2e --config-file=cypress.config.ts",
"cy:run": "cypress run",
"e2e": "start-server-and-test start:test http://localhost:61812 cy:run",
"mocha": "pnpm --filter backend run mocha",
"test": "pnpm run mocha",
"format": "gulp format",
"clean": "pnpm node ./scripts/clean.js",
"clean-all": "pnpm node ./scripts/clean-all.js",
"cleanall": "pnpm run clean-all"
},
"resolutions": {
"chokidar": "^3.3.1"
},
"dependencies": {
"@bull-board/api": "^4.10.2",
"@bull-board/ui": "^4.10.2",
"@napi-rs/cli": "^2.15.0",
"@tensorflow/tfjs": "^3.21.0",
"calckey-js": "^0.0.22",
"js-yaml": "4.1.0",
"seedrandom": "^3.0.5"
},
"devDependencies": {
"@types/gulp": "4.0.10",
"@types/gulp-rename": "2.0.1",
"cross-env": "7.0.3",
"cypress": "10.11.0",
"execa": "5.1.1",
"gulp": "4.0.2",
"gulp-cssnano": "2.1.3",
"gulp-rename": "2.0.0",
"gulp-replace": "1.1.4",
"gulp-terser": "2.1.0",
"install-peers": "^1.0.4",
"rome": "^11.0.0",
"start-server-and-test": "1.15.2",
"typescript": "4.9.4"
}
}