### Install and Run Vuex Examples
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/vuex/4.0.0/node_modules/vuex/README.md
Commands to install dependencies and serve the example applications for Vuex.
```bash
npm install
npm run dev # serve examples at localhost:8080
```
--------------------------------
### Install and Run Vuex Examples
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/vuex/3.1.0/node_modules/vuex/README.md
Commands to install dependencies and serve the Vuex examples locally.
```bash
$ npm install
$ npm run dev # serve examples at localhost:8080
```
--------------------------------
### Install Astro
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Astro/astro-tests/testData/node_modules/astro/1.9.0/node_modules/astro/README.md
Use the recommended 'npm create astro@latest' for a guided setup or 'npm install --save-dev astro' for manual installation.
```bash
# Recommended!
npm create astro@latest
```
```bash
# Manual:
npm install --save-dev astro
```
--------------------------------
### Makefile Install Command for Renderer
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue46.txt
This snippet demonstrates installing a renderer-specific library, using variables like INSTALL, STRIP_FLAG, BR, SHLIBNAME, and COPYBINDIR. It's part of a conditional installation process.
```makefile
$(INSTALL) $(STRIP_FLAG) -m 0755 $(BR)/renderer_opengl1_$(SHLIBNAME) $(COPYBINDIR)/renderer_opengl1_$(SHLIBNAME)
```
--------------------------------
### VueUse Core Usage Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/vueuse/9.3.0/node_modules/@vueuse/core/README.md
Demonstrates how to import and use common utilities like useMouse, usePreferredDark, and useLocalStorage in a Vue 3 setup function. These utilities help track mouse position, detect user's preferred color scheme, and persist data in local storage.
```typescript
import { useLocalStorage, useMouse, usePreferredDark } from '@vueuse/core'
export default {
setup() {
// tracks mouse position
const { x, y } = useMouse()
// is user prefers dark theme
const isDark = usePreferredDark()
// persist state in localStorage
const store = useLocalStorage(
'my-storage',
{
name: 'Apple',
color: 'red',
},
)
return { x, y, isDark, store }
},
}
```
--------------------------------
### Install Dependencies
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/highlighting/standalonePseudoModules/node_modules/igniteui-angular/README.md
Install project dependencies from the root folder.
```bash
npm install
```
--------------------------------
### Install vue-meta with npm
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/nuxt/2.13.2/node_modules/vue-meta/README.md
Install the vue-meta package using npm.
```sh
$ npm install vue-meta --save
```
--------------------------------
### Install Naive UI with npm
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/naive-ui/2.19.11/node_modules/naive-ui/README.md
Use npm to install Naive UI as a development dependency.
```bash
npm i -D naive-ui
```
--------------------------------
### Install iView via npm
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/iview/3.5.4/node_modules/iview/README.md
Use this command to install the iView library as a project dependency.
```bash
npm install iview --save
```
--------------------------------
### Conditional Installation for Client
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue46.txt
This snippet executes an INSTALL command if the BUILD_CLIENT variable is not set to '0'. This is typically used for client-side installations.
```makefile
ifneq ($(BUILD_CLIENT),0)
$(INSTALL)
```
--------------------------------
### CMake Project Setup
Source: https://github.com/jetbrains/intellij-plugins/blob/master/qodana/cpp/test-data/cmake-broken-test/CMakeLists.txt
Defines the minimum CMake version and project name. Ensure the specified version is compatible with your CMake installation.
```cmake
cmake_minimum_required(VERSION 3.25)
project(cmake-broken-test)
```
--------------------------------
### Install Cordova CLI
Source: https://github.com/jetbrains/intellij-plugins/blob/master/phoneGap/README.md
Installs the Cordova command-line interface globally using npm.
```bash
$npm install -g cordova
```
--------------------------------
### Consuming a source map example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/nuxt/2.15.6/node_modules/@nuxt/types/node_modules/source-map/README.md
Example demonstrating how to use SourceMapConsumer to get information about original source positions.
```APIDOC
### Consuming a source map
```js
var rawSourceMap = {
version: 3,
file: 'min.js',
names: ['bar', 'baz', 'n'],
sources: ['one.js', 'two.js'],
sourceRoot: 'http://example.com/www/js/',
mappings: 'CAAC,IAAI,IAAM,SAAUA,GAClB,OAAOC,IAAID;CCDb,IAAI,IAAM,SAAUE,GAClB,OAAOA'
};
var smc = new SourceMapConsumer(rawSourceMap);
console.log(smc.sources);
// [ 'http://example.com/www/js/one.js',
// 'http://example.com/www/js/two.js' ]
console.log(smc.originalPositionFor({
line: 2,
column: 28
}));
// { source: 'http://example.com/www/js/two.js',
// line: 2,
// column: 10,
// name: 'n' }
console.log(smc.generatedPositionFor({
source: 'http://example.com/www/js/two.js',
line: 2,
column: 10
}));
// { line: 2, column: 28 }
smc.eachMapping(function (m) {
// ...
});
```
```
--------------------------------
### Install vue-meta with Yarn
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/nuxt/2.13.2/node_modules/vue-meta/README.md
Install the vue-meta package using Yarn.
```sh
$ yarn add vue-meta
```
--------------------------------
### Install and Build Vue Language Server
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-backend/vue-language-tools/language-server/README.md
Run these commands to install dependencies and build the Vue language server. Ensure you have adjusted versions in `package.json` and `VueServices.kt` before building.
```shell
npm i
npm run build
```
--------------------------------
### Install ios-sim
Source: https://github.com/jetbrains/intellij-plugins/blob/master/phoneGap/README.md
Installs the ios-sim tool globally using npm, required for iOS app simulation.
```bash
$npm install -g ios-sim
```
--------------------------------
### Install Astro Compiler
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Astro/astro-language-server/bin/node_modules/@astrojs/compiler/README.md
Install the Astro compiler package using npm.
```bash
npm install @astrojs/compiler
```
--------------------------------
### Install Ionic CLI
Source: https://github.com/jetbrains/intellij-plugins/blob/master/phoneGap/README.md
Installs the Ionic command-line interface globally using npm.
```bash
$npm install -g ionic
```
--------------------------------
### Install PhoneGap CLI
Source: https://github.com/jetbrains/intellij-plugins/blob/master/phoneGap/README.md
Installs the PhoneGap command-line interface globally using npm.
```bash
$npm install -g phonegap
```
--------------------------------
### Install vfonts with npm
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/naive-ui/2.19.11/node_modules/naive-ui/README.md
Install the vfonts package, which provides fonts for Naive UI.
```bash
npm i -D vfonts
```
--------------------------------
### Ensuring Composition API Installation with install()
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/pinia/2.0.22/node_modules/vue-demi/README.md
The install() API ensures the Composition API plugin is correctly installed on the Vue instance. In Vue 3 environments, it acts as a no-op.
```typescript
import { install } from 'vue-demi'
install()
```
--------------------------------
### Install Ignite UI for Angular
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/highlighting/standalonePseudoModules/node_modules/igniteui-angular/README.md
Install the igniteui-angular and igniteui-cli packages to your project.
```bash
ng add igniteui-angular
```
--------------------------------
### Install source-map with Node.js
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/nuxt/2.15.6/node_modules/@nuxt/types/node_modules/source-map/README.md
Install the source-map library using npm for use in Node.js projects.
```bash
$ npm install source-map
```
--------------------------------
### Start Development Server with Angular CLI
Source: https://github.com/jetbrains/intellij-plugins/blob/master/js-karma/testData/runConfiguration/angularV21AndAngularDevkitBuildAngularPkg/README.md
Run this command to start a local development server. The application automatically reloads on source file changes.
```bash
ng serve
```
--------------------------------
### Install Vuelidate with npm
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/vuelidate/node_modules/vuelidate/README.md
Install Vuelidate using npm for your Vue.js project.
```bash
npm install vuelidate --save
```
--------------------------------
### Install Schematics CLI
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/@ionic
Install the schematics-cli globally to run schematics locally. This step is temporary until schematics are published.
```bash
npm install @angular-devkit/schematics-cli
```
--------------------------------
### Vue Template with Script Setup
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/html/parser/testFirstEverScriptInTemplate.txt
A Vue template using the `
```
--------------------------------
### WebAssembly Vector Constant Example (Commented Out)
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/Const.txt
This is a commented-out example showing the structure for `v128.const` with `i32x4` elements. It illustrates how to define 128-bit vector constants.
```WebAssembly
(; v128.const i32x4 0x11223344 0x55667788 0x99aabbcc 0xddeeff00
drop
v128.const i32x4 0x11223344 1432778632 2578103244 0xddeeff00
drop;)
```
--------------------------------
### Makefile Install Command with Variables
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue46.txt
This snippet shows an installation command in a Makefile that uses several variables for paths and flags. It's used within a conditional block.
```makefile
$(INSTALL) $(STRIP_FLAG) -m 0755 $(BR)/$(CLIENTBIN)$(FULLBINEXT) $(COPYBINDIR)/$(CLIENTBIN)$(FULLBINEXT)
```
--------------------------------
### Run Demo Application
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/highlighting/standalonePseudoModules/node_modules/igniteui-angular/README.md
Build the library and start the demo application to showcase components.
```bash
npm start
```
--------------------------------
### WebAssembly Module with get_local Examples
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/GetlocalIndexMixedNamedUnnamed.txt
This snippet defines a WebAssembly module with parameters and local variables, then uses get_local to access them. It includes examples of accessing locals by both numerical index and named identifier.
```webassembly
(module
(param "i32")
(param $n "f32")
(local "i32" "i64")
(local $m "f64")
(instr (get_local 0))
(instr drop)
(instr (get_local 1))
(instr drop)
(instr (get_local $n)) ;; 1
(instr drop)
(instr (get_local)
)
```
--------------------------------
### Prisma Binary Paths on Windows
Source: https://github.com/jetbrains/intellij-plugins/blob/master/mdx/testData/parsing/ParsingPrisma.MDX.txt
Example output showing the current platform and the path to the query engine binary on Windows.
```text
Current platform : windows
```
--------------------------------
### Makefile Comment Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue142.txt
Demonstrates how the Makefile parser handles single-line comments starting with '#'.
```makefile
# abc \n# cde
should still be a comment
```
```makefile
# abc \n# cde
should still be a comment
and this
```
```makefile
# abc \n# cde
should still be a comment
and this
and this too
```
--------------------------------
### WebAssembly Table Get Instruction
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/TableGet.txt
This snippet demonstrates the use of the `table.get` instruction to retrieve an element from a table. It requires a table to be defined and an index to specify which element to get. The index must be a valid unsigned integer.
```WebAssembly
(func (result externref)
i32.const 0
table.get 0
)
```
--------------------------------
### Prisma Binary Paths Output Example (Unix/MacOS)
Source: https://github.com/jetbrains/intellij-plugins/blob/master/mdx/testData/parsing/ParsingPrisma.txt
This output shows the current platform and the path to the query engine binary. It confirms that the query engine is located at the specified custom path.
```text
Current platform : darwin
|Query Engine : query-engine d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /custom/my-query-engine-windows)
Migration Engine : migration-engine-cli d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /myproject/node_modules/@prisma/cli/migration-engine-windows)
```
--------------------------------
### Define Memory Node for 4GB RAM
Source: https://github.com/jetbrains/intellij-plugins/blob/master/dts/testData/documentation/bundled/MemoryBinding.html
Defines a memory node for a 4GB RAM range starting at address 0x100000000. This example assumes '#address-cells' and '#size-cells' are both set to 2.
```dts
memory@100000000 {
device_type = "memory";
reg = <0x000000001 0x00000000 0x00000001 0x00000000>;
};
```
--------------------------------
### Prisma Binary Paths on Unix/MacOS
Source: https://github.com/jetbrains/intellij-plugins/blob/master/mdx/testData/parsing/ParsingPrisma.MDX.txt
Example output showing the current platform and the path to the query engine binary on Unix-like systems.
```text
Current platform : darwin
|Query Engine : query-engine d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /custom/my-query-engine-windows)
Migration Engine : migration-engine-cli d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /myproject/node_modules/@prisma/cli/migration-engine-windows)
Introspection Engine : introspection-core d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /myproject/node_modules/@prisma/cli/introspection-engine-windows)
Format Binary : prisma-fmt d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /myproject/node_modules/@prisma/cli/prisma-fmt-windows)
```
--------------------------------
### Define Memory Node for 2GB RAM
Source: https://github.com/jetbrains/intellij-plugins/blob/master/dts/testData/documentation/bundled/MemoryBinding.html
Defines a memory node for a 2GB RAM range starting at address 0x0. This example assumes '#address-cells' and '#size-cells' are both set to 2.
```dts
memory@0 {
device_type = "memory";
reg = <0x000000000 0x00000000 0x00000000 0x80000000>;
};
```
--------------------------------
### Makefile Rule Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Multiline.txt
Demonstrates a basic Makefile rule with a target and prerequisites.
```makefile
test: hello world
```
--------------------------------
### Standalone Repeat Expression with Filters
Source: https://github.com/jetbrains/intellij-plugins/blob/master/AngularJS/testResources/org/angularjs/lang/parser/data/expressions.txt
This example demonstrates a standalone AngularJS repeat expression with filters, separate from an 'ng-repeat' directive context. It applies 'started' and 'search' filters to 'todoService.todos'.
```javascript
let todo
todoService.todos | started: status | search: term
```
--------------------------------
### Angular @else Block with Content
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/html/parser_V_17/testIncompleteParameters.txt
A basic @else block that correctly defines its start and end markers for content. This snippet serves as a valid contrast to the incomplete parameter examples.
```html
@else
{
}
```
--------------------------------
### AngularJS Repeat Expression with Filters
Source: https://github.com/jetbrains/intellij-plugins/blob/master/AngularJS/testResources/org/angularjs/lang/parser/data/expressions.txt
An example of an AngularJS repeat expression using 'let...of' syntax, combined with multiple filters ('started' and 'search') applied to a service's todos.
```javascript
let todo of todoService.todos | started: status | search: term
```
--------------------------------
### Set Custom Query Engine Binary Path
Source: https://github.com/jetbrains/intellij-plugins/blob/master/mdx/testData/parsing/ParsingPrisma.txt
Use the PRISMA_QUERY_ENGINE_BINARY environment variable to specify a custom path for the Prisma query engine binary. This is useful for custom installations or specific project setups.
```bash
PRISMA_QUERY_ENGINE_BINARY=c:\\custom\\path\\my-query-engine-binary
```
--------------------------------
### Build MyLib Project
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/inspections/ngModuleImport/localLib/after/dist/my-lib/README.md
Run this command to build the MyLib project. The output artifacts will be placed in the `dist/` directory.
```bash
ng build my-lib
```
--------------------------------
### Prisma Binary Paths Output (Windows)
Source: https://github.com/jetbrains/intellij-plugins/blob/master/mdx/testData/parsing/ParsingPrisma.mdx
Example output from `npx prisma -v` on Windows, showing the query engine path sourced from the PRISMA_QUERY_ENGINE_BINARY environment variable.
```text
Current platform : windows
|Query Engine : query-engine d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at c:\custom\my-query-engine-windows.exe)
Migration Engine : migration-engine-cli d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at c:\myproject\node_modules\@prisma\cli\migration-engine-windows.exe)
Introspection Engine : introspection-core d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at c:\myproject\node_modules\@prisma\cli\introspection-engine-windows.exe)
Format Binary : prisma-fmt d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at c:\myproject\node_modules\@prisma\cli\prisma-fmt-windows.exe)
```
--------------------------------
### Install Ghostscript Fonts on macOS
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/rxjs/6.4.0/node_modules/rxjs/README.md
Manually install Ghostscript fonts on macOS after installing Ghostscript. Download the tarball from the gs-fonts project and extract it to the appropriate directory.
```bash
mkdir -p /usr/local/share/ghostscript && tar zxvf /path/to/ghostscript-fonts.tar.gz -C /usr/local/share/ghostscript
```
--------------------------------
### WebAssembly If/Return Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/IfReturn.txt
Demonstrates a function with an if-else block that uses the return instruction. This is useful for conditional logic and early exit from functions.
```webassembly
(module
(func (result i32)
i32.const 1
if (result i32)
i32.const 2
return
else
i32.const 3
return
end
)
)
```
--------------------------------
### Makefile Command Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue46.txt
This snippet shows a typical Makefile command line with variable substitutions and output redirection.
```makefile
$(Q) $(Q3ASM) $(ASMFLAGS) -o $@ $(MPCGVMOBJ) $(CGDIR)/cg_syscalls.asm
```
--------------------------------
### Prisma Binary Paths Output (Unix/MacOS)
Source: https://github.com/jetbrains/intellij-plugins/blob/master/mdx/testData/parsing/ParsingPrisma.mdx
Example output from `npx prisma -v` on Unix-like systems, showing the query engine path sourced from the PRISMA_QUERY_ENGINE_BINARY environment variable.
```text
Current platform : darwin
|Query Engine : query-engine d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /custom/my-query-engine-windows)
Migration Engine : migration-engine-cli d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /myproject/node_modules/@prisma/cli/migration-engine-windows)
Introspection Engine : introspection-core d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /myproject/node_modules/@prisma/cli/introspection-engine-windows)
Format Binary : prisma-fmt d6ff7119649922b84e413b3b69660e2f49e2ddf3 (at /myproject/node_modules/@prisma/cli/prisma-fmt-windows)
```
--------------------------------
### WebAssembly br_table Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/BrtableMulti.txt
Demonstrates the br_table instruction with multiple target labels. The instruction takes a list of labels and a default label. Execution jumps to the label corresponding to the value on top of the stack, or the default label if the value is out of bounds.
```webassembly
(block
(block
(block
(block
(block
i32.const 0
br_table 4 3 2 1 0
end
nop
end
nop
end
nop
end
end
)
```
--------------------------------
### Makefile Rule with Build Target
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue143.txt
Demonstrates a basic Makefile rule with a 'build' target, a prerequisite 'info', and a recipe that echoes 'building'. Comments indicate redundancy.
```makefile
build : info # < Redundant rule
@echo building
```
--------------------------------
### Makefile CLIENT_CFLAGS Echo Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue46.txt
Shows how CLIENT_CFLAGS are echoed in a Makefile.
```makefile
@echo "CLIENT_CFLAGS:"
```
--------------------------------
### WebAssembly f64 Select Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/Select.txt
Demonstrates the 'select' instruction with f64 values. It selects between two f64 values based on a condition. The 'drop' instruction is used to discard the result.
```webassembly
(module
(func (result f64)
f64.const 2
f64.const 3
i32.const 1
select
drop
)
)
```
--------------------------------
### Build JAR with Maven
Source: https://github.com/jetbrains/intellij-plugins/blob/master/cucumber-java/testData/renameStep/notWritableStep/project/README.md
Use this command to clean and package the project into a JAR file.
```shell
mvn clean package
```
--------------------------------
### Vue Script Setup with TypeScript Class
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/html/parser/testScriptsWithMixedLanguages.txt
Illustrates a TypeScript class defined within a Vue component's setup script. Suitable for defining component logic or data structures in a setup context.
```typescript
class XS {}
```
--------------------------------
### WebAssembly br_table Instruction Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/Brtable.txt
Demonstrates the usage of the br_table instruction to jump to different labels based on an index. This is useful for implementing multi-way branching.
```webassembly
(module
(func
(block
(block
i32.const 0
br_table 0 1
end
nop
end
nop
end
)
```
--------------------------------
### Build API Documentation
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/highlighting/standalonePseudoModules/node_modules/igniteui-angular/README.md
Build the API documentation using TypeDoc and SassDoc.
```bash
npm run build:docs
```
--------------------------------
### Get Relative Path
Source: https://github.com/jetbrains/intellij-plugins/blob/master/flex/flex-tests/testData/flex_importer/airglobal_1_5.swc.txt
Gets the relative path of this file with respect to another file reference.
```APIDOC
## Get Relative Path
### Description
Gets the relative path of this file with respect to another file reference.
### Method
`getRelativePath(ref:flash.net.FileReference,useDotDot:Boolean = false):String`
### Parameters
* **ref** (flash.net.FileReference) - The reference file.
* **useDotDot** (Boolean) - Optional - If true, uses '..' for parent directories. Defaults to false.
```
--------------------------------
### WebAssembly i64 Select Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/Select.txt
Demonstrates the 'select' instruction with i64 values. Similar to i32, it selects between two i64 values based on a condition. The 'drop' instruction is used to discard the result.
```webassembly
(module
(func (result i64)
i64.const 2
i64.const 3
i32.const 1
select
drop
)
)
```
--------------------------------
### Create Angular Project
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/@ionic
Steps to create a new Angular project for testing purposes. Ensure to include the router when prompted.
```bash
ng new add-test
// Say yes to including the router, we need it
cd add-test
```
--------------------------------
### Install Ghostscript for macOS
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/rxjs/6.4.0/node_modules/rxjs/README.md
Use Homebrew to install Ghostscript on macOS. This is a prerequisite for generating marble diagrams.
```bash
brew install ghostscript
```
--------------------------------
### Install GraphicsMagick for macOS
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/rxjs/6.4.0/node_modules/rxjs/README.md
Use Homebrew to install GraphicsMagick on macOS. This is a prerequisite for generating marble diagrams.
```bash
brew install graphicsmagick
```
--------------------------------
### CMake Project Setup and Executable Definition
Source: https://github.com/jetbrains/intellij-plugins/blob/master/qodana/cpp/test-data/build-system-selection-test/CMakeLists.txt
Defines the minimum CMake version and project name, then adds an executable target named 'main' that compiles 'main.cpp'.
```cmake
cmake_minimum_required(VERSION 3.25)
project(build-system-selection-test)
add_executable(main main.cpp)
```
--------------------------------
### Install ImageMagick for macOS
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/rxjs/6.4.0/node_modules/rxjs/README.md
Use Homebrew to install ImageMagick on macOS. This is a prerequisite for generating marble diagrams.
```bash
brew install imagemagick
```
--------------------------------
### WebAssembly f64.store with offset
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/StoreOffset.txt
Demonstrates the f64.store instruction with a specified offset. Ensure the offset is correctly formatted.
```webassembly
f64.const 0
f64.store offset=8
```
--------------------------------
### Verify Prisma Binary Paths
Source: https://github.com/jetbrains/intellij-plugins/blob/master/mdx/testData/parsing/ParsingPrisma.mdx
Run this command to display the paths of all Prisma binaries, including the query engine. This helps confirm that the environment variable is correctly set.
```terminal
npx prisma -v
```
--------------------------------
### Install Ghostscript for Debian Linux
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/rxjs/6.4.0/node_modules/rxjs/README.md
Install Ghostscript on Debian Linux systems. This is a prerequisite for generating marble diagrams.
```bash
apt-get install ghostscript
```
--------------------------------
### Install GraphicsMagick for Debian Linux
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/node_modules/rxjs/6.4.0/node_modules/rxjs/README.md
Install GraphicsMagick on Debian Linux systems. This is a prerequisite for generating marble diagrams.
```bash
apt-get install graphicsmagick
```
--------------------------------
### Build Ignite UI for Angular Library
Source: https://github.com/jetbrains/intellij-plugins/blob/master/Angular/angular-tests/testData/highlighting/standalonePseudoModules/node_modules/igniteui-angular/README.md
Commands to build the library, CSS, or both.
```bash
// build the code
ng build igniteui-angular
// build the css
npm run build:style
// build them both
npm run build:lib
```
--------------------------------
### WebAssembly br_table Instruction Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/web-assembly-plugin/src/test/resources/parser/expr/BrtableNamed.txt
Demonstrates the use of the br_table instruction with multiple target labels and a default target. This is useful for implementing switch-case like structures.
```webassembly
(module
(func (export "switch")
(block $exit
(block $1
(block $0
i32.const 0
br_table $0 $1 $exit
)
nop
)
nop
)
)
)
```
--------------------------------
### Media Range Syntax Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/postcss/paid/resources/inspectionDescriptions/PostCssMediaRange.html
This example demonstrates the basic usage of the media range syntax for screen width.
```css
@media screen and (500px <= width <= 1200px) {}
```
--------------------------------
### Create Qcommon Directory if Not Exists
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue46.txt
This snippet checks if the qcommon directory within the base game path exists. If it does not, it creates the directory using the MKDIR variable.
```makefile
! -d $(B)/$(BASEGAME)/qcommon ; then \
$(MKDIR) $(B)/$(BASEGAME)/qcommon ;
fi
```
--------------------------------
### Basic Vuelidate Setup with Validators
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/node_modules/vuelidate/node_modules/vuelidate/README.md
Configure validations for component data properties using imported validators like required, minLength, and between.
```javascript
import { required, minLength, between } from 'vuelidate/lib/validators'
export default {
data () {
return {
name: '',
age: 0
}
},
validations: {
name: {
required,
minLength: minLength(4)
},
age: {
between: between(20, 30)
}
}
}
```
--------------------------------
### CSS Full Comment Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/PerforceIntegration/testResources/testData/changes.txt
Provides an example of a CSS comment that includes content. This demonstrates how comments are structured.
```css
/**a **/
```
```java
CSS_COMMENT ('/**a **/' )
```
--------------------------------
### Makefile Command Echo Example
Source: https://github.com/jetbrains/intellij-plugins/blob/master/makefile/testData/parser/Issue46.txt
Shows a simple Makefile command that echoes an empty string.
```makefile
@echo ""
```
--------------------------------
### defineOptions
Source: https://github.com/jetbrains/intellij-plugins/blob/master/vuejs/vuejs-tests/testData/completion/scriptSetupGlobalsTs/items.txt
Allows defining component options directly within