jsverse/transloco-keys-manager

normalizedGlob does not find the path to the package nested in the directory

JSProto opened this issue · 0 comments

I have a monorepository with the nx library.
packages of different projects are in separate directories.

libs/
   project1/
      mypackage
   project2/
       otherpackage

when I create a package through the nx console, its name in libs/project2/otherpackage/package.json looks like project2-otherpackage

{
  "name": "project2-otherpackage",
  "$schema": "../../../node_modules/nx/schemas/project-schema.json",
  "projectType": "library",

https://github.com/ngneat/transloco-keys-manager/blob/9affd8edebdf3520c9f499b73de88325d8ca7506/src/utils/resolve-project-base-path.ts#L48
because of this projectName - normalizedGlob does not find the path to the package nested in the directory

If you manually change the name to project2/otherpackage then everything works.

{
  "name": "project2/otherpackage",
  "$schema": "../../../node_modules/nx/schemas/project-schema.json",
  "projectType": "library",

can this be fixed?