Giter Club home page Giter Club logo

Comments (6)

frankcalise avatar frankcalise commented on May 25, 2024 2

@morganick probably related: expo/expo-cli#1073 (comment)

from ignite.

morganick avatar morganick commented on May 25, 2024 1

@frankcalise I was able to replicate the issue above with the following steps:

  1. Use yarn 1.22.22 to Ignite a new project
  2. @naoyamakino is using yarn 4.1.1 so let's move to that yarn set version stable
  3. yarn install && yarn ios
  4. 🙌 the application builds without issue.
  5. rm -rf node_modules and edit the .yarnrc.yml file to remove the line nodeLinker: node-modules
  6. yarn install && yarn ios
  7. 💥 the error that @naoyamakino is seeing above

The reason this works for switching to yarn 4.1.1 after the application is Ignited the first time is that yarn 4.1.1 will migrate the repo on first yarn install after setting the new yarn version:

➤ YN0087: Migrated your project to the latest Yarn version 🚀

This adds the missing piece to our .yarnrc.yml file: nodeLinker: node-modules.

I thought we were detecting the yarn version and adding this into the .yarnrc.yml file, but I can't find a reference to that in the repo.

@naoyamakino adding nodeLinker: node-modules to your .yarnrc.yml will get things working for you. Otherwise, yarn goes into PnP mode, which I've yet to see work on any project 😅. You may also see the following folders and directories from PnP that you can get rid of:

.pnp.cjs
.pnp.loader.mjs
.yarn/unplugged

@naoyamakino thanks for reporting the issue 🙌

from ignite.

naoyamakino avatar naoyamakino commented on May 25, 2024

Thanks! I believe that worked! I am having a separate issue, which seems to be related to expo/expo#28345, but that is at least different from what I faced in this issue. thank you for resolving this!

from ignite.

morganick avatar morganick commented on May 25, 2024

You're welcome @naoyamakino 🙌 Happy coding!

@frankcalise shall we close this as an expo issue or did we want to do yarn version detection?

from ignite.

frankcalise avatar frankcalise commented on May 25, 2024

You're welcome @naoyamakino 🙌 Happy coding!

@frankcalise shall we close this as an expo issue or did we want to do yarn version detection?

@morganick So if we wanted to enhance the cli to work with yarn 2+, what would that look like?

Something like this we did for pnpm depending on the yarn version? https://github.com/infinitered/ignite/blob/master/src/commands/new.ts#L615-L621

from ignite.

morganick avatar morganick commented on May 25, 2024

@frankcalise Yes! That's the one I was thinking about! Yeah, we could do something similar for Yarn 2+.

from ignite.

Related Issues (20)

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.