UNPKG

@zsnout/ithkuil

Version:

A set of tools which can generate and parse romanized Ithkuil text and which can generate Ithkuil script from text and JSON data.

59 lines (58 loc) 3.49 kB
{ "name": "@zsnout/ithkuil", "version": "0.1.121", "description": "A set of tools which can generate and parse romanized Ithkuil text and which can generate Ithkuil script from text and JSON data.", "author": "sakawi", "license": "MIT", "type": "module", "scripts": { "build": "tsc -b", "cleanup": "rm -f data/**/*.js; rm -f generate/**/*.js; rm -f gloss/**/*.js; rm -f parse/**/*.js; rm -f script/**/*.js; rm -f test/**/*.js; rm -f ungloss/**/*.js; rm -f *.js", "cleanup2": "rm -f data/**/*.d.ts; rm -f generate/**/*.d.ts; rm -f gloss/**/*.d.ts; rm -f parse/**/*.d.ts; rm -f script/**/*.d.ts; rm -f test/**/*.d.ts; rm -f ungloss/**/*.d.ts; rm -f *.d.ts", "fetch:affixes": "tsc -b && rm -f ./data/affixes-latest.ts && node -e \"import('./data/affixes.js').then(x => x.getAffixes(process.env.ITHKUIL_DATA_API_KEY)).then(x => fs.writeFileSync('./data/affixes-latest.ts', 'import type { AffixEntry } from \\'./affixes.js\\'\\nimport { deepFreeze } from \\'../generate/helpers/deep-freeze.js\\'\\n\\nexport const affixes = /* @__PURE__ */ deepFreeze<AffixEntry[]>(' + JSON.stringify(x).replaceAll('null','') + ')'))\"", "fetch:roots": "tsc -b && rm -f ./data/roots-latest.ts && node -e \"import('./data/roots.js').then(x => x.getRoots(process.env.ITHKUIL_DATA_API_KEY)).then(x => fs.writeFileSync('./data/roots-latest.ts', 'import type { RootEntry } from \\'./roots.js\\'\\nimport { deepFreeze } from \\'../generate/helpers/deep-freeze.js\\'\\n\\nexport const roots = /* @__PURE__ */ deepFreeze<RootEntry[]>(' + JSON.stringify(x).replaceAll('null','') + ')'))\"", "fetch-data": "npm run fetch:affixes; npm run fetch:roots; npx prettier --write data/*-latest.ts", "lint": "prettier --write .", "prepublish": "tsc -b", "pretest": "tsc -b", "start": "if [ -f playground.ts ]; then\n npx tsc -b && node playground.js\nelse\n echo \"import { wordToIthkuil } from \\\"./generate/index.js\\\"\nimport { parseWord } from \\\"./parse/index.js\\\"\n\n/**\n * This file allows for quick experimentation with this project's functions. To\n * do so, import anything you need in the statement above and play around with\n * the imports below.\n */\n\n// Be a tribe that works together towards a common goal.\nconst result1 = wordToIthkuil({\n type: \\\"UNF/K\\\",\n shortcut: true,\n root: \\\"l\\\",\n ca: { configuration: \\\"MFS\\\", affiliation: \\\"COA\\\" },\n context: \\\"RPS\\\",\n illocutionValidation: \\\"DIR\\\",\n})\n\nconsole.log(result1)\n\n// me (beneficial, ergative) and you (detrimental, absolutive)\nconst result2 = parseWord(\\\"royež\\\")\n\nconsole.log(result2)\" > ./playground.ts\nfi", "test": "node test/generate.js && node test/parse.js" }, "repository": { "type": "git", "url": "git+https://github.com/zsakowitz/ithkuil.git" }, "keywords": [ "conlang", "generator", "ithkuil", "ithkuil-iv", "new-ithkuil", "parser", "text", "text-generator", "tnil" ], "bugs": { "url": "https://github.com/zsakowitz/ithkuil/issues" }, "homepage": "https://github.com/zsakowitz/ithkuil#readme", "devDependencies": { "@types/node": "^20.5.6", "esbuild": "^0.18.11", "prettier": "^3.4.2", "prettier-plugin-jsdoc": "^1.3.0", "typescript": "^5.7.2" }, "dependencies": { "@zsnout/ithkuil-jsx": "^0.1.3", "fast-fuzzy": "^1.12.0", "zod": "^3.21.4" }, "files": [ "**/*.d.ts", "**/*.js", "**/*.mjs", "**/*.json" ] }