# react-web-music-project **Repository Path**: javafdx/react-web-music-project ## Basic Information - **Project Name**: react-web-music-project - **Description**: react12练习项目 - **Primary Language**: JavaScript - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2022-12-30 - **Last Updated**: 2023-01-30 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README #### 安装 create-react-app hy-music-web-react create-react-app : 无法将“create-react-app”项识别为 cmdlet、函数、脚本文件或可运行程序的名称。请检查名称的拼写,如果 包括路径,请确保路径正确,然后再试一次。 失败: npx create-react-app hy-music-web-react Need to install the following packages: create-react-app Ok to proceed? (y) y 解决方案是 在create-react-app my-app命令前面,加上npx指令。如下: npx create-react-app my-app 1 执行之后,果然顺利创建了! 原因是: npx 会自动查找当前依赖包中的可执行文件,如果找不到,就会去 PATH 里找。如果依然找不到,就会帮你安装。 ### 屏蔽浏览器显示raect-tools插件 https://github.com/facebook/react-devtools/issues/191 // disable react-dev-tools for this project if (typeof window.__REACT_DEVTOOLS_GLOBAL_HOOK__ === "object") { for (let [key, value] of Object.entries(window.__REACT_DEVTOOLS_GLOBAL_HOOK__)) { window.__REACT_DEVTOOLS_GLOBAL_HOOK__[key] = typeof value == "function" ? ()=>{} : null; } }