Replies: 2 comments 1 reply
-
Glad the site has been helpful ! And thanks for giving me cause to take a look at this issue. Turns out the inconsistency i was seeing wasn't due to the Targets logic but: A) using the wrong path for "Inputs" ( tailblazor.dev's current build Target from <Target Name="npm install" BeforeTargets="tailwind build" Inputs="./package.json" Outputs="./node_modules/.install-stamp">
<Exec Command="npm install" />
<Touch Files="./node_modules/.install-stamp" AlwaysCreate="true" />
</Target> Regarding usage of Regarding touch files: Unless i'm mistaken, the only thing that matters about the Inputs and Outputs are the files' timestamps. Copying Poking around a bit i noticed a I've changed my local "npm install" target to use it, as follows (again excluding the <Target Name="npm install" BeforeTargets="tailwind build" Inputs="./package.json" Outputs="./node_modules/.package-lock.json">
<Message Text="npm install target running..." Importance="high"></Message>
<Exec Command="npm install" />
<Message Text="npm install target finished !" Importance="high"></Message>
</Target> Comparing the timestamp of my possibly-manually-edited I'll use this for a while and see how it goes. (Note to self: if all goes well, Let me know if i've missed something ! Incremental build docs: https://docs.microsoft.com/en-us/visualstudio/msbuild/how-to-build-incrementally |
Beta Was this translation helpful? Give feedback.
-
I've merged a new So far: Regarding the Other changes from my original A couple things i haven't squeezed into the text (yet?):
|
Beta Was this translation helpful? Give feedback.
-
Hey,
First off, thanks for the fantastic resource! Been using tailwind with blazor for over a year now and went to upgrade to tailwind 3, figured I'd look at if anyone came up with better integration and tooling, this is exactly what I needed to renovate and update my projects a bit.
One thing I found when I was combining information from a lot of different sources into one smooth process (sorry, I am going to try to find references to it, but it's been over a year since I setup my project and I forgot to take notes), is triggering the npm install off package-lock.json being watched for changes instead of a touch file.
Any reason this isn't a viable candidate? Maybe it isn't as smooth as using the touch file since you're depending on copying files, but the package-lock file changing is a pretty solid indicator of when a new npm install would need to take place if it hadn't already.
Beta Was this translation helpful? Give feedback.
All reactions