I think you're wanting to use "injections"
.
It will inject rules into your own grammar.
Heres the schema for it "$schema": "https://raw.githubusercontent.com/RedCMD/TmLanguage-Syntax-Highlighter/main/vscode.tmLanguage.schema.json"
Injections documentation
"injections": {
"L:source.phpf -comment -string": {
"patterns": [
{
"name": "phpf.a",
"match": "___[A-Z]+___"
}
]
}
}
"injectionSelector"
& "injectTo"
is used when you want to inject your language into an existing language.
currently "injectTo": ["source.php"]
is injecting your phpf
into the existing php
language.
making "include": "source.php"
redundant.