PNPM monorepo with NuxtJS & NestJS

112 views Asked by At

Hello fellow developer,

While creating a basic pnpm monorepo with two folders in a workspace:

  • packages with an app folder housing a NuxtJS app

  • services with an app folder housing a NestJS app

I encountered an 500 error with the following message:

[vite-node] [ERR_LOAD_URL] /Shared/FooEnum

within the NuxtJS app while trying to access shared files from the services/app folder in the about.vue component.

<template>
  <h1>About page</h1>
</template>

<script setup lang="ts">
import { BarEnum, FooEnum } from "@hgtronic/service-app/src/Shared/Enums";
console.log("foo enum " + FooEnum.Foo1);
console.log("bar enum " + BarEnum.Bar1);
</script>

I've created a repository under this link, I would greatly appreciate your help.

Thank you for reading.

My goal is to access shared files from the sevices/app folder.

I've looked at all tsconfig.json files in the project but I couldn't find the reason for the error.

Perhaps I need to adjust nuxt.config.ts file?

0

There are 0 answers