This notification can't be turned off unfortunately - annotator-level inspections can't be suppressed. The issue with relative paths resolving when loading plugins for non-js extensions is tracked as WEB-1167, please vote
Stop Webstorm of Displaying Error on hbs! Plugin for require.js
-
25-06-2023 - |
Question
There are two files in my project:
index.js where the following code is
define([ 'exports', 'hbs!./general'], function (exports, generalTemplate) { });
general.handlebars which is correctly taken by require.js and the
hbs!
plug-in.
I'm basically using Require.js with Handlebars.js and the https://github.com/SlexAxton/require-handlebars-plugin for automating the creation of templates from files.
It works correctly, but Webstorm 8 (and also 7 before it) doesn't understand the file is correct so it always complains with: Cannot resolve file 'general'. It is the same with every file using that plugin prefix.
I coudln't find where (if it exists) to turn that notification off, because it underlines the entire file, and its parent directories as having errors.
How can I remove this error of being reported?
Solution