wRadion
wRadion
DDeno
Created by wRadion on 1/9/2025 in #help
Import local package in sub folder workspace
Okay I've managed to fix my issue (that was quick lol). Writing it actually helped me understand that maybe the @scope thing is named scope, because it represents the workspace scope (I'm dumb 😅 ). So the idea is simply to declare the submodule in the root workspace:
root
|- add
|- deno.json // @scope/add
|- index.ts
|- substract
|- deno.json // @scope/substract
|- index.ts
|- maths
|- geometry
|- deno.json
|- index.ts // finds @scope/add or @scope/substract
|- deno.json // workspace: ["./add", "./substract", "./maths/geometry"]
root
|- add
|- deno.json // @scope/add
|- index.ts
|- substract
|- deno.json // @scope/substract
|- index.ts
|- maths
|- geometry
|- deno.json
|- index.ts // finds @scope/add or @scope/substract
|- deno.json // workspace: ["./add", "./substract", "./maths/geometry"]
2 replies