说明:

在npm install 后,会出现Scanning files to index ...... 出现这个是正常的,但是一直不消失就不正常了。原因是npm install 后 node_modules 内增加了文件夹,但是文件路劲太深所以 才造成phpstorm 一直卡在了 Scanning files to index.... 状态。之后会出现提示框,也就是提示说给phpstorm分配的内存太少。但是,自己要知道,并不是分配的内存少哦。

解决:

右击 node_modules文件夹,并按如图操作点击,也就是让phpstorm不加在这个文件夹。 

如果要取消的话:

你点击File --Project Structure,然后左边选Modules,然后选Sources,然后点击你刚才Excluded掉的文件夹,然后把Mark as后面的Excluded点掉 就可以了。如果你Excluded了好多次,那就重复点击取消Excluded,如图

 
其他说明:
1. 选择mark directory as test sources root,意思是把文件夹设置为源代码根路径,
2. 选择mark directory as test resources root,意思是把文件夹设置为资源文件根路径

intellij idea中Mark Directory As里的Sources Root、ReSources Root等的区别:

1. Source roots (or source folders)

By assigning a folder to this category, you tell IntelliJ IDEA that this folder and its subfolders contain source code that should be compiled as part of the build process.

2. Test source roots (or test source folders; shown as rootTest)

These roots are similar to source roots but are for code intended for testing (e.g. for unit tests). Test source folders let you keep the code related to testing separate from the production code.

Compilation results for sources and test sources, normally, are placed into different folders.

3. Resource roots

are for resource files used in your application (images, various configuration XML and properties files, etc.).

During the build process, all the contents of the resource folders are copied to the output folder as is.

Similarly to sources, you can specify that your resources are generated. You can also specify which folder within the output folder your resources should be copied to.

4. Test resource roots

(or test resource folders; shown as rootTestResourceIJ; available only in Java modules) are for resource files associated with your test sources. In all other respects, these folders are similar to resource folders.

**5. Excluded roots (shown as rootExcluded) are ones that IntelliJ IDEA

“almost ignores”.**

Very limited coding assistance is provided for files in excluded
folders. Classes contained in excluded folders don’t appear in code
completion suggestion lists, references to such classes are shown in the
editor as unresolved. When searching, IntelliJ IDEA doesn’t look in
excluded folders, etc.

intellij 打开node项目 一直停留在scanning files to index....,或跳出内存不够的提示框的更多相关文章

  1. phpstorm(或webstorm) 打开后 一直停留在scanning files to index....,或跳出内存不够的提示框

    记得3月份做项目时就遇到过这个问题,当时解决的 ,但是忘记怎么解决的啦,所以 ,写博文是多么的重要啊. 说明: 在npm install 后,会出现Scanning files to index .. ...

  2. webstorm 打开后 一直停留在scanning files to index....,或跳出内存不够的提示框

    用着有时会这样,超级卡, 网上搜了下,原来如此,记录下,免得忘了. ------------------------- 说明: 在npm install 后,会出现Scanning files to ...

  3. node--->PHPStorm 停留在 Scanning files to index..

    使用webpack时,敲了npm 一些命令后,PHPStorm 开始 Scanning files to index...,去建立文件索引,但是如果一直停留在这个状态,说明是npm install 后 ...

  4. webstorm加载项目卡死在scanning files to index

    今天用webstorm导入项目时,需要加载node-modules文件夹,导致webstorm非常卡,页面提示scanning files to index... 网上搜到办法,记录下: 说明: 在n ...

  5. webstorm 提示 "scanning files to index..." 一直不能编译的问题

    先说一下我的操作过程吧: 下载公司的vue项目后,要用到webpack打包工具,需要按照package.json安装一些依赖,我使用了镜像后,npm install模块时候生成了一个 node_mod ...

  6. pycharm一直scanning files to index

    删除了c盘的垃圾文件之后,pycharm就一直scanning files to index 解决方法: 点击file,然后选择invalidate caches / restart ...,再弹出的 ...

  7. IDEA Intellij 打开springboot项目 配置文件无法出现输入提示

    需要将java代码和资源文件进行标记

  8. webstrom 很卡 底下一直走进度条 scanning files to index

    最近工作总会遇到一些问题 先说说webstrom 其中有一次仅仅开了两个项目 电脑风扇就各种轰鸣 各种重启 安装卸载webstrom 都没有作用 好吧 其实解决很简单 选择一个文件夹,右键, Mark ...

  9. webstorm 很卡 scanning files to index (扫描文件索引)

    webstorm 号称"前端神器",但npm导入包跑索引,会很卡不停的跑索引... 排除你不想索引的文件夹 找到你想排除的文件夹(主要是node_modulewe文件夹),右键选择 ...

随机推荐

  1. Python——网络爬虫

    此篇文章继续跟着小甲鱼的视频来初学网络爬虫,除了小甲鱼的网站上可下载视频,发现b站上也有全套的视频哦,会比下载来的更方便些. 网络爬虫,又称为网页蜘蛛(WebSpider),非常形象的一个名字.如果你 ...

  2. django作业练习

    ---权限管理系统 要求: 1,登陆: a,装饰器判断用户是否已经登陆 b,用户密码使用md5发送 2,注册 a,检测用户是否已经存在,onblur+ajax光标跳出输入框时(使用ajax) 3,注销 ...

  3. shopxx------list列表回显修改尝试

    需求:在商品列表展示页面增加一列 一.修改模板 1.列表页面对应的freemarker模板位置 /shopxx/WebContent/WEB-INF/template/admin/product/li ...

  4. System.UnauthorizedAccessException 错误

    给目录添加 "Authenticated Users" 这个用户的 读写权限

  5. 《Linux命令行与shell脚本编程大全》第十九章 初识sed和gawk

    这两个工具能够极大简化需要进行的数据处理任务. 19.1 文本处理 能轻松实现自动格式化.插入.修改或删除文本元素的简单命令行编辑. sed和gawk就具备上述功能 19.1.1 sed编辑器 被称为 ...

  6. JavaScript各种继承方式和优缺点

    好久没写博客啦,嘻嘻,这个月是2017年的最后一个月啦,大家应该都开始忙着写年终总结了吧,嘻嘻,小颖今天给大家分享下Javascript中的几种继承方式以及他们的优缺点. 1.借助构造函数实现继承 原 ...

  7. 制作支持 BIOS+UEFI 的 U 盘 grub2+bootmgr 引导 + deepin_recovery + deepin_iso + win_pe

    网盘下载:https://pan.baidu.com/s/1c2GXPo0 U盘为 FAT32,MBR分区表 1.下载:U盘grub2+bootmgr引导2017.12.6.2.7z 2.解压到 U盘 ...

  8. Solidity教程系列1 - 类型介绍

    现在的Solidity中文文档,要么翻译的太烂,要么太旧,决定重新翻译下,再加上代码事例讲解. 写在前面 Solidity是以太坊智能合约编程语言,阅读本文前,你应该对以太坊.智能合约有所了解, 如果 ...

  9. 学习makefile的一个工程示例

    前言 makefile推荐资料为陈皓的跟我一起写makefile,需要pdf资源的可以私我 正文 工程目录结构 ---include(放置头文件.h) ------student.h(Student类 ...

  10. 简单的基于Vue-axios请求封装

    具体实现思路=>封装之前需要用npm安装并引入axios,使用一个单独的js模块作为接口请输出对象,然后export dafult 这个对象. 1.首先我们需要在Vue实例的原型prototyp ...