Cannot find module '@babel/plugin-transform-react-jsx-source' when running React App












5















I have just created a React App with create-react-app aquastars and then eject the dependencies using yarn run eject and when I run the app I get the following error.



Cannot find module '@babel/plugin-transform-react-jsx-source'


I haven't done anything! What do I need to do to get this up and running? Any help would be appreciated.










share|improve this question


















  • 1





    npm install ?

    – connexo
    Nov 15 '18 at 20:44











  • Thanks connexo I am running that now.

    – AltBrian
    Nov 15 '18 at 20:46











  • same issue, how did you solve it?

    – Adir Zoari
    Nov 26 '18 at 10:10
















5















I have just created a React App with create-react-app aquastars and then eject the dependencies using yarn run eject and when I run the app I get the following error.



Cannot find module '@babel/plugin-transform-react-jsx-source'


I haven't done anything! What do I need to do to get this up and running? Any help would be appreciated.










share|improve this question


















  • 1





    npm install ?

    – connexo
    Nov 15 '18 at 20:44











  • Thanks connexo I am running that now.

    – AltBrian
    Nov 15 '18 at 20:46











  • same issue, how did you solve it?

    – Adir Zoari
    Nov 26 '18 at 10:10














5












5








5


1






I have just created a React App with create-react-app aquastars and then eject the dependencies using yarn run eject and when I run the app I get the following error.



Cannot find module '@babel/plugin-transform-react-jsx-source'


I haven't done anything! What do I need to do to get this up and running? Any help would be appreciated.










share|improve this question














I have just created a React App with create-react-app aquastars and then eject the dependencies using yarn run eject and when I run the app I get the following error.



Cannot find module '@babel/plugin-transform-react-jsx-source'


I haven't done anything! What do I need to do to get this up and running? Any help would be appreciated.







javascript reactjs






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 15 '18 at 20:44









AltBrianAltBrian

330320




330320








  • 1





    npm install ?

    – connexo
    Nov 15 '18 at 20:44











  • Thanks connexo I am running that now.

    – AltBrian
    Nov 15 '18 at 20:46











  • same issue, how did you solve it?

    – Adir Zoari
    Nov 26 '18 at 10:10














  • 1





    npm install ?

    – connexo
    Nov 15 '18 at 20:44











  • Thanks connexo I am running that now.

    – AltBrian
    Nov 15 '18 at 20:46











  • same issue, how did you solve it?

    – Adir Zoari
    Nov 26 '18 at 10:10








1




1





npm install ?

– connexo
Nov 15 '18 at 20:44





npm install ?

– connexo
Nov 15 '18 at 20:44













Thanks connexo I am running that now.

– AltBrian
Nov 15 '18 at 20:46





Thanks connexo I am running that now.

– AltBrian
Nov 15 '18 at 20:46













same issue, how did you solve it?

– Adir Zoari
Nov 26 '18 at 10:10





same issue, how did you solve it?

– Adir Zoari
Nov 26 '18 at 10:10












4 Answers
4






active

oldest

votes


















7














I solve it!



after you executed 'npm run eject'



1.cd your project path (ignore)



2.rm -rf node_modules



3.npm install (don't use yarn )



npm run start success






share|improve this answer



















  • 2





    Why not yarn in the 3rd step 🤔. I tried installing with yarn. It worked 😕

    – user2925949
    Feb 2 at 20:30



















6














The solution by @xiaobo was actually insufficient for me. It took me a while to figure this out after upgrading expo to v32, so here's what I did in case anyone else has the same problem. (Answer from expo forums.)



If you have a .babelrc file in the root of your repository, re-name it to something like .babelrc-old so it doesn't get used.



Add a file called babel.config.js to the root of your repository.



Put this in the babel.config.js file:



module.exports = function(api) {
api.cache(true);
return {
presets: ['babel-preset-expo'],
};
};


All set!






share|improve this answer


























  • Welcome to Stack Overflow! It looks like a good first answer, but please edit your post to remove the reference to "the answer above" because the answer order can change.

    – A Jar of Clay
    Jan 18 at 17:15











  • Hey, got it, thanks so much for the tip! I just edited it to link to the actual answer.

    – Nando
    Feb 15 at 17:20











  • Thanks @Nando, you saved my day!

    – Fl4v
    Mar 9 at 20:47



















0














Delete the whole node_modules and re-run yarn to make it work.

rm -R node_modules/
rm yarn.lock
yarn install






share|improve this answer































    0














    Try to replace '@babel/plugin-transform-react-jsx-source' with '@babel/transform-react-jsx-source'






    share|improve this answer























      Your Answer






      StackExchange.ifUsing("editor", function () {
      StackExchange.using("externalEditor", function () {
      StackExchange.using("snippets", function () {
      StackExchange.snippets.init();
      });
      });
      }, "code-snippets");

      StackExchange.ready(function() {
      var channelOptions = {
      tags: "".split(" "),
      id: "1"
      };
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function() {
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled) {
      StackExchange.using("snippets", function() {
      createEditor();
      });
      }
      else {
      createEditor();
      }
      });

      function createEditor() {
      StackExchange.prepareEditor({
      heartbeatType: 'answer',
      autoActivateHeartbeat: false,
      convertImagesToLinks: true,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: 10,
      bindNavPrevention: true,
      postfix: "",
      imageUploader: {
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      },
      onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      });


      }
      });














      draft saved

      draft discarded


















      StackExchange.ready(
      function () {
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53327625%2fcannot-find-module-babel-plugin-transform-react-jsx-source-when-running-react%23new-answer', 'question_page');
      }
      );

      Post as a guest















      Required, but never shown

























      4 Answers
      4






      active

      oldest

      votes








      4 Answers
      4






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      7














      I solve it!



      after you executed 'npm run eject'



      1.cd your project path (ignore)



      2.rm -rf node_modules



      3.npm install (don't use yarn )



      npm run start success






      share|improve this answer



















      • 2





        Why not yarn in the 3rd step 🤔. I tried installing with yarn. It worked 😕

        – user2925949
        Feb 2 at 20:30
















      7














      I solve it!



      after you executed 'npm run eject'



      1.cd your project path (ignore)



      2.rm -rf node_modules



      3.npm install (don't use yarn )



      npm run start success






      share|improve this answer



















      • 2





        Why not yarn in the 3rd step 🤔. I tried installing with yarn. It worked 😕

        – user2925949
        Feb 2 at 20:30














      7












      7








      7







      I solve it!



      after you executed 'npm run eject'



      1.cd your project path (ignore)



      2.rm -rf node_modules



      3.npm install (don't use yarn )



      npm run start success






      share|improve this answer













      I solve it!



      after you executed 'npm run eject'



      1.cd your project path (ignore)



      2.rm -rf node_modules



      3.npm install (don't use yarn )



      npm run start success







      share|improve this answer












      share|improve this answer



      share|improve this answer










      answered Nov 30 '18 at 5:55









      xiaoboxiaobo

      27628




      27628








      • 2





        Why not yarn in the 3rd step 🤔. I tried installing with yarn. It worked 😕

        – user2925949
        Feb 2 at 20:30














      • 2





        Why not yarn in the 3rd step 🤔. I tried installing with yarn. It worked 😕

        – user2925949
        Feb 2 at 20:30








      2




      2





      Why not yarn in the 3rd step 🤔. I tried installing with yarn. It worked 😕

      – user2925949
      Feb 2 at 20:30





      Why not yarn in the 3rd step 🤔. I tried installing with yarn. It worked 😕

      – user2925949
      Feb 2 at 20:30













      6














      The solution by @xiaobo was actually insufficient for me. It took me a while to figure this out after upgrading expo to v32, so here's what I did in case anyone else has the same problem. (Answer from expo forums.)



      If you have a .babelrc file in the root of your repository, re-name it to something like .babelrc-old so it doesn't get used.



      Add a file called babel.config.js to the root of your repository.



      Put this in the babel.config.js file:



      module.exports = function(api) {
      api.cache(true);
      return {
      presets: ['babel-preset-expo'],
      };
      };


      All set!






      share|improve this answer


























      • Welcome to Stack Overflow! It looks like a good first answer, but please edit your post to remove the reference to "the answer above" because the answer order can change.

        – A Jar of Clay
        Jan 18 at 17:15











      • Hey, got it, thanks so much for the tip! I just edited it to link to the actual answer.

        – Nando
        Feb 15 at 17:20











      • Thanks @Nando, you saved my day!

        – Fl4v
        Mar 9 at 20:47
















      6














      The solution by @xiaobo was actually insufficient for me. It took me a while to figure this out after upgrading expo to v32, so here's what I did in case anyone else has the same problem. (Answer from expo forums.)



      If you have a .babelrc file in the root of your repository, re-name it to something like .babelrc-old so it doesn't get used.



      Add a file called babel.config.js to the root of your repository.



      Put this in the babel.config.js file:



      module.exports = function(api) {
      api.cache(true);
      return {
      presets: ['babel-preset-expo'],
      };
      };


      All set!






      share|improve this answer


























      • Welcome to Stack Overflow! It looks like a good first answer, but please edit your post to remove the reference to "the answer above" because the answer order can change.

        – A Jar of Clay
        Jan 18 at 17:15











      • Hey, got it, thanks so much for the tip! I just edited it to link to the actual answer.

        – Nando
        Feb 15 at 17:20











      • Thanks @Nando, you saved my day!

        – Fl4v
        Mar 9 at 20:47














      6












      6








      6







      The solution by @xiaobo was actually insufficient for me. It took me a while to figure this out after upgrading expo to v32, so here's what I did in case anyone else has the same problem. (Answer from expo forums.)



      If you have a .babelrc file in the root of your repository, re-name it to something like .babelrc-old so it doesn't get used.



      Add a file called babel.config.js to the root of your repository.



      Put this in the babel.config.js file:



      module.exports = function(api) {
      api.cache(true);
      return {
      presets: ['babel-preset-expo'],
      };
      };


      All set!






      share|improve this answer















      The solution by @xiaobo was actually insufficient for me. It took me a while to figure this out after upgrading expo to v32, so here's what I did in case anyone else has the same problem. (Answer from expo forums.)



      If you have a .babelrc file in the root of your repository, re-name it to something like .babelrc-old so it doesn't get used.



      Add a file called babel.config.js to the root of your repository.



      Put this in the babel.config.js file:



      module.exports = function(api) {
      api.cache(true);
      return {
      presets: ['babel-preset-expo'],
      };
      };


      All set!







      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Feb 15 at 17:18

























      answered Jan 18 at 16:56









      NandoNando

      6113




      6113













      • Welcome to Stack Overflow! It looks like a good first answer, but please edit your post to remove the reference to "the answer above" because the answer order can change.

        – A Jar of Clay
        Jan 18 at 17:15











      • Hey, got it, thanks so much for the tip! I just edited it to link to the actual answer.

        – Nando
        Feb 15 at 17:20











      • Thanks @Nando, you saved my day!

        – Fl4v
        Mar 9 at 20:47



















      • Welcome to Stack Overflow! It looks like a good first answer, but please edit your post to remove the reference to "the answer above" because the answer order can change.

        – A Jar of Clay
        Jan 18 at 17:15











      • Hey, got it, thanks so much for the tip! I just edited it to link to the actual answer.

        – Nando
        Feb 15 at 17:20











      • Thanks @Nando, you saved my day!

        – Fl4v
        Mar 9 at 20:47

















      Welcome to Stack Overflow! It looks like a good first answer, but please edit your post to remove the reference to "the answer above" because the answer order can change.

      – A Jar of Clay
      Jan 18 at 17:15





      Welcome to Stack Overflow! It looks like a good first answer, but please edit your post to remove the reference to "the answer above" because the answer order can change.

      – A Jar of Clay
      Jan 18 at 17:15













      Hey, got it, thanks so much for the tip! I just edited it to link to the actual answer.

      – Nando
      Feb 15 at 17:20





      Hey, got it, thanks so much for the tip! I just edited it to link to the actual answer.

      – Nando
      Feb 15 at 17:20













      Thanks @Nando, you saved my day!

      – Fl4v
      Mar 9 at 20:47





      Thanks @Nando, you saved my day!

      – Fl4v
      Mar 9 at 20:47











      0














      Delete the whole node_modules and re-run yarn to make it work.

      rm -R node_modules/
      rm yarn.lock
      yarn install






      share|improve this answer




























        0














        Delete the whole node_modules and re-run yarn to make it work.

        rm -R node_modules/
        rm yarn.lock
        yarn install






        share|improve this answer


























          0












          0








          0







          Delete the whole node_modules and re-run yarn to make it work.

          rm -R node_modules/
          rm yarn.lock
          yarn install






          share|improve this answer













          Delete the whole node_modules and re-run yarn to make it work.

          rm -R node_modules/
          rm yarn.lock
          yarn install







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Feb 5 at 10:22









          RKMRKM

          84




          84























              0














              Try to replace '@babel/plugin-transform-react-jsx-source' with '@babel/transform-react-jsx-source'






              share|improve this answer




























                0














                Try to replace '@babel/plugin-transform-react-jsx-source' with '@babel/transform-react-jsx-source'






                share|improve this answer


























                  0












                  0








                  0







                  Try to replace '@babel/plugin-transform-react-jsx-source' with '@babel/transform-react-jsx-source'






                  share|improve this answer













                  Try to replace '@babel/plugin-transform-react-jsx-source' with '@babel/transform-react-jsx-source'







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Feb 10 at 7:52









                  Risen humanRisen human

                  262




                  262






























                      draft saved

                      draft discarded




















































                      Thanks for contributing an answer to Stack Overflow!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid



                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.


                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function () {
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53327625%2fcannot-find-module-babel-plugin-transform-react-jsx-source-when-running-react%23new-answer', 'question_page');
                      }
                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown







                      Popular posts from this blog

                      Bressuire

                      Vorschmack

                      Quarantine