Git Product home page Git Product logo

nx-cache-issue-minimal-example's Introduction

CacheIssue Reproduce

This is a stripped version of the project in which this happens:

# clear cache
rm -rf node_modules/.cache
# build lib (with CI flag enabled to force in-process-hash)
CI=true npx nx run-many -t build --projects=some-lib
# build app (with CI flag enabled to force in-process-hash)
CI=true npx nx run-many -t build --projects=some-app

First output, as expected, builds lib

 >  NX   Running target build for project some-lib:

    - some-lib

 —————————————————————————————————————————————————————————————————————————————————————————————————————

> nx run some-lib:build:production

vite v4.3.9 building for production...
transforming...
✓ 3 modules transformed.
rendering chunks...
computing gzip size...
../../dist/packages/some-lib/style.css  0.00 kB │ gzip: 0.02 kB
../../dist/packages/some-lib/index.mjs  0.24 kB │ gzip: 0.19 kB
../../dist/packages/some-lib/index.js  0.25 kB │ gzip: 0.21 kB

[vite:dts] Start generate declaration files...
✓ built in 2.47s
[vite:dts] Declaration files built in 2174ms.


 —————————————————————————————————————————————————————————————————————————————————————————————————————

 >  NX   Successfully ran target build for project some-lib

Second output, surprisingly, builds lib again

 >  NX   Running target build for project some-app and 1 task it depends on:

    - some-app

 —————————————————————————————————————————————————————————————————————————————————————————————————————

> nx run some-lib:build:production

vite v4.3.9 building for production...
transforming...
✓ 3 modules transformed.
rendering chunks...
computing gzip size...
../../dist/packages/some-lib/style.css  0.00 kB │ gzip: 0.02 kB
../../dist/packages/some-lib/index.mjs  0.24 kB │ gzip: 0.19 kB
../../dist/packages/some-lib/index.js  0.25 kB │ gzip: 0.21 kB

[vite:dts] Start generate declaration files...
✓ built in 2.25s
[vite:dts] Declaration files built in 2054ms.


> nx run some-app:build:production

vite v4.3.9 building for production...
transforming...
✓ 35 modules transformed.
rendering chunks...
computing gzip size...
../../dist/apps/some-app/index.html                   0.48 kB │ gzip:  0.30 kB
../../dist/apps/some-app/assets/index-e3b0c442.css    0.00 kB │ gzip:  0.02 kB
../../dist/apps/some-app/assets/index-5f41df50.js   166.34 kB │ gzip: 51.75 kB
✓ built in 1.09s

 —————————————————————————————————————————————————————————————————————————————————————————————————————

 >  NX   Successfully ran target build for project some-app and 1 task it depends on

nx-cache-issue-minimal-example's People

Contributors

gerarts avatar

Watchers

 avatar

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.