没有api/common/notice.js
时间: 2023-12-20 09:07:10 浏览: 33
如果在你的项目中没有 `api/common/notice.js` 文件,那么可能是该文件还没有被创建或者被放置在了其他路径中。
请按照以下步骤解决问题:
1. 确保你需要导入的模块在项目中已经存在或者被正确命名。
2. 如果 `api/common/notice.js` 文件还没有被创建,你可以手动创建该文件,并在其中编写相应的代码。根据你的需求,你可以定义 `crudMethod` 和 `noticeInfoForId` 函数,或者从其他文件中导入这些函数。
3. 如果 `api/common/notice.js` 文件已经被创建,但是放置在了不正确的路径下,你需要将导入语句中的路径修改为正确的路径。确保路径与文件的实际位置相匹配。
4. 如果你不确定正确的路径或文件名,可以尝试使用编辑器的搜索功能来找到包含所需函数的文件。搜索你想要导入的函数名称,看看是否能够找到正确的文件。
5. 如果你的代码是从其他项目或示例中获取的,请确保你已经正确地复制了所有相关文件,并且路径和命名都是正确的。
如果以上步骤都不能解决问题,请提供更多相关代码和错误信息,以便我能够更具体地帮助你解决问题。
相关问题
These dependencies were not found: * core-js/fn/promise in ./src/util/formHtml.js * file-saver in ./src/util/formHtml.js To install them, you can run: npm install --save core-js/fn/promise file-saver These relative modules were not found: * ../../../service/api in ./src/util/element/child.js, ./src/util/vant/child.js * ../../router/router in ./src/util/formHtml.js * ../../service/common in ./src/util/data.js * ../../service/storage in ./src/util/data.js * ../form/control/index in ./src/util/formHtml.js 给我中文解析
这些依赖项未找到:
* 在./src/util/formHtml.js中的core-js/fn/promise
* 在./src/util/formHtml.js中的file-saver
要安装它们,可以运行:npm install --save core-js/fn/promise file-saver
这些相对模块未找到:
* 在./src/util/element/child.js、./src/util/vant/child.js中的../../../service/api
* 在./src/util/formHtml.js中的../../router/router
* 在./src/util/data.js中的../../service/common
* 在./src/util/data.js中的../../service/storage
* 在./src/util/formHtml.js中的../form/control/index
@/api/common/notice
`@/api/common/notice` 是一个相对于项目根目录的路径别名,用于引入 `api/common/notice` 模块。
在解决模块未找到的问题时,你可以尝试以下几个步骤:
1. 确保在项目根目录下存在 `api/common/notice.js` 或 `api/common/notice/index.js` 文件。这个文件应该包含对应模块的实现代码。
2. 检查你的项目配置中是否正确设置了 `@` 别名,通常是指向项目的根目录。你可以在 webpack 配置文件或者 vue-cli 的配置文件中查找别名的设置,并确保其正确指向项目根目录。
3. 确保你已经安装了 `api/common/notice` 模块所依赖的相关包。你可以通过运行 `npm install` 或 `yarn install` 来安装依赖。
如果以上步骤都没有解决问题,请提供更多相关的代码和错误信息,以便我能够更具体地帮助你解决问题。
相关推荐
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)