Paths to resources
PACKAGE_NAME:RELATIVE_PATH_TO_FILE
If the file is contained in the application directory, then the path must be specified without the ":" character.
DIRECTORY1/DIRECTORY2
or begin with the : symbol, thereby indicating that the path is specified from the application root
:DIRECTORY1/DIRECTORY2
On the server side, paths starting with "/" or "X:\" are considered absolute paths.
On the browser side, paths starting with "XXX://" or c "/" are considered absolute paths.
To get the real path to the file, you can use the
To use paths with the package on the browser side, you must specify the path where the package will be available.
By default, all packages are loaded from the /node_modules directory URL. This path is specified in the webModuleDirectory configuration parameter. If the packages on your server are stored in a different directory, then you need to change the webModuleDirectory configuration parameter:
fcf.getConfiguration().
If the package on your server is not available from the main package directory, then the correct path can be specified individually for the individual package. To do this, in the sources configuration parameter, you need to create an object with a key equal to the package name and set the webPackagePath parameter in it, which will point to the URL directory from which the package files will be downloaded.
fcf.getConfiguration().
Packages in the framework are normal NODEJS packages and no additional steps are required to use them. But if you want to include a directory that contains additional NODEJS packages, you can use the moduleDirectories configuration parameter, which should contain an array of strings with directories that contain NODEJS packages on the server side.
fcf.getConfiguration().
For the convenience of compiling paths in the framework, an alias mechanism is implemented to shorten the path to the resource. Paths using aliases begin with the @ special character followed by the alias name up to delimiters (
You can use the
Adding an alias is done by adding to the configuration parameter aliases (type
fcf.getConfiguration().