WebStorm无法找到导出函数的用法

时间:2017-07-03 06:26:15

标签: javascript node.js webstorm jetbrains-ide

我有一个包含一些函数的js文件名business_video.js。最后我导出它们:

  module.exports = {
        checkShare,
        checkDownloadFile,
        uploadVideo,
        quickTransferVideo,
        searchVideoInshared,
        renameVideo,
        deleteVideo,
        addTags,
        deleteTag,
        downloadFileToFromHDFSToServer,
        doesFileExistInServer,
        videoSquare,
        getVideoInfoByIdsArray
    }

我想在整个项目中找到函数名getVideoInfoByIdsArray的用法,包括使用const abc = require('../business_video')然后abc.getVideoInfoByIdsArray()的用户。

然而,当我按F7时,我 function getVideoInfoByIdsArray(){...}它显示唯一的用法是module.exports={...}。如何在整个项目中找到用法?

2 个答案:

答案 0 :(得分:0)

进行全局查找,默认键映射为 ctrl + shift + F ,并按文件掩码 js 进行过滤,取消选中 case , /或 regex ,而是项目选择目录并设置项目的根目录。在搜索框中粘贴功能名称。如果没有结果,意味着没有使用!

答案 1 :(得分:-1)

使用export before declaration,然后“查找用法”也会在其他模块上查找用法。

相关问题