-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Themosis Framework: loader paths #47
Comments
Hello! If you're using Symfony, it should gather custom namespaces by running the twiggy/packages/language-server/src/twigEnvironment/SymfonyTwigEnvironment.ts Lines 50 to 58 in 1e9acae
If not, let me know which framework you’re using |
Thanks, im using the Themosis Framework which incorporates a Laravel environment to a Wordpress installation. Would it be possible to create a custom configuration / FrameworkEnvironment for this use case? |
Is there a way to programmatically resolve namespaces? For example, Symfony provides a CLI tool which has an option to query all the info about the current environment:
{
...
"loader_paths": {
...
"@Twig": [
"templates\/bundles\/TwigBundle"
],
"@!Twig": [
"templates\/bundles\/TwigBundle"
],
"(None)": [
"templates"
]
}
} Or maybe the overall file structure is predefined? Otherwise, we'll have to add an option to manually pass loader paths to the extension. This would also cover the cases like #2 |
I am using twiggy in neovim and am very pleased with the overall features and experience.
However i was wondering if its possible to somehow point the "Go to definition" action for a template in a custom namespace (eg. @atoms/template/template.twig) to the correct path in the filesystem?
Thanks a lot
Christian
The text was updated successfully, but these errors were encountered: