Git Product home page Git Product logo

Comments (15)

Floffah avatar Floffah commented on May 29, 2024 1

fixed in 1.0.6, properly tested this time and definitely works.

from esbuild-plugin-d.ts.

Floffah avatar Floffah commented on May 29, 2024 1

alright ill look into this when i get time thank you!

from esbuild-plugin-d.ts.

Floffah avatar Floffah commented on May 29, 2024

ah yeah this must have been broken when I switched to using conf.conf.compilerOptions because just passing conf.conf makes it not even read the config at all.
to fix this I could check if the extends property is there and create a new object which is a spread of the extended config and the project config to pick it up

thank you for the issue :)

from esbuild-plugin-d.ts.

gablabelle avatar gablabelle commented on May 29, 2024

Screen Shot 2021-06-20 at 10 17 54

Path resolution seems to be problematic in your 1.0.5 release.

In my case, monorepo root is /Users/gabriel.labelle/Developer/workjam/workjam-web-next and extended config is located at /Users/gabriel.labelle/Developer/workjam/workjam-web-next/tsconfig.settings.json

The lib is located /Users/gabriel.labelle/Developer/workjam/workjam-web-next/libs/ui-atoms.

Hope it helps. Does not hesitate if you need more info.

from esbuild-plugin-d.ts.

Floffah avatar Floffah commented on May 29, 2024

how are you using esbuild in these projects? the plugin relies on working directories

it resolves the extended by using the tsconfig file it found (typescript does this for the plugin using the process.cwd()) and then the plugin uses the path it found to resolve the extended config from that

maybe its picking up your root config instead of the package config?

would it be handy if i added an option to set the working directory for the plugin to use?

from esbuild-plugin-d.ts.

gablabelle avatar gablabelle commented on May 29, 2024

It's a monorepo (yarn) like this one:

https://github.com/gablabelle/next-mesh-apollo-monorepo-example

tsconfig in each packages extend the tsconfig at root of the monorepo.

from esbuild-plugin-d.ts.

Floffah avatar Floffah commented on May 29, 2024

where is esbuild being run though? I suspect its a problem with that so Ill make it configurable for where it checks

from esbuild-plugin-d.ts.

gablabelle avatar gablabelle commented on May 29, 2024

It is run in each package folders (packages/*).

from esbuild-plugin-d.ts.

Floffah avatar Floffah commented on May 29, 2024

can't think of a valid fix so I've just added an option to override the config path. Please install the package from the repository (esbuild-plugin-d.ts@floffah/esbuild-plugin-d.ts) and add this option and tell me if it works. if this is inconvenient I can continue to look for a fix or if you can think of one feel free to open a pull request

just realised the problem, will make a new release fixing it

from esbuild-plugin-d.ts.

sachinraja avatar sachinraja commented on May 29, 2024

Seeing this issue (also with "declarationMap": true) in the root tsconfig.build.json. Seems to only be reading from the package's tsconfig.build.json because it works when I put the option in there.

from esbuild-plugin-d.ts.

Floffah avatar Floffah commented on May 29, 2024

Seeing this issue (also with "declarationMap": true) in the root tsconfig.build.json. Seems to only be reading from the package's tsconfig.build.json because it works when I put the option in there.

could you provide a reproducible example so i can understand this better?
i have a feeling its a problem with moving to the incremental program/host and may be fixed with the solution to #8

from esbuild-plugin-d.ts.

Floffah avatar Floffah commented on May 29, 2024

Seeing this issue (also with "declarationMap": true) in the root tsconfig.build.json. Seems to only be reading from the package's tsconfig.build.json because it works when I put the option in there.

After rereading I have a few ideas as to what this could be

What is the working directory of the process when you run esbuild? If it's the root of the project that'll be the problem as it finds the first one it sees inline with a package.json using a function provided by typescript

from esbuild-plugin-d.ts.

sachinraja avatar sachinraja commented on May 29, 2024

Sorry for the delay, here's a repro. Issue seems to be that I set declarationDir, removing that fixes it.

from esbuild-plugin-d.ts.

verikono avatar verikono commented on May 29, 2024

I had a similar issue adjusting. Resolved by modifying:

{
	"extends": "@tsconfig/vite-react/tsconfig.json",
        .....
}

to

{
	"extends": "./node_modules/@tsconfig/vite-react/tsconfig.json",
        ...
}

from esbuild-plugin-d.ts.

Related Issues (7)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.