A language syntax highlighter and code completion extension for editing Xule with Visual Studio Code.
Workspace, Settings and Taxonomy Files
The settings .zip file below includes a Visual Studio Code .code-workspace and settings files corresponding to the reference implementation code (source folder) included in every Data Quality Committee Rules release (DQC).
The files in the .zip linked below include:
a DQC.code-workspace file defining folders corresponding to the reference implementation
settings.json files that define imports and namespaces required by the Xule Editor in each workspace folder, and
US GAAP (2014 - 2023) and IFRS (2018 - 2023) Taxonomies in .json format called by the settings.json files.
Together, these resources enable highlighting and code completion in the Xule Editor.
Download and extract all folders and files from the dqc-xule-settings.zip archive into the dqc_us_rules subdirectory of the release, so that the taxonomy folder is at the same level as the existing source folder.
Proceed with caution - the extract process will create or replace existing workspace, settings and taxonomy files in the DQC reference implementation source folder structure. If you are not sure how to proceed safely, consider manually copying from the files in the .zip into the appropriate settings file. XBRL US is not responsible for overwritten settings.
Confirming the Xule Editor extension
Once the DQC.code-workspace and .json files are extracted, open the DQC.code-workspace file from Visual Studio Code's "Open Workspace..." prompt under the program's File menu. Browse the folders by year (US GAAP above IFRS, separated by a common lib folder), and open a .xule file for one of the DQC Rules. If the Visual Studio Code view includes underlined text in the body of the editor, warnings or errors listed for the file (like the image at left below), try the following steps:
Check the location of the settings.json file(s) and the contents of the file itself against the corresponding file(s) in the .zip, to be sure the xule.autoImports and xule.namespaces.definitions are correct.
Check the location of the taxonomy folder and its contents, to be sure it matches the contents of the .zip archive.
MacOS users might need to remove the '../../lib/' string from the functions.xule and version.xule entries in the settings.json files.
Check that the settings.json file is being read properly by the Xule Editor extension - open the settings for the extension, then browse to the corresponding folder(s) using the dropdown, to confirm that the Auto Imports and Namespaces: Definitions are listed (like the image at right below). If not, try uninstalling and reinstalling the Xule Editor extension.