ember-language-server
ember-language-server copied to clipboard
Pods support
This PR introduces support for discovering routes and components in pod directories (#53). This allows completion in templates as well as support for "go to definition".
Everything seems to be working, and existing tests are passing, ~but additional tests need to be added.~ and additional tests for pods are added and working.
Also, the method used for discovering the correct podModulePrefix probably needs fixing and tweaking for nested projects. I could use some help/guidance there as I'm not completely familiar with those scenarios.
- [x] Old tests passing
- [x] New tests added (and passing)
Some other things in this PR worth noting:
-
Robustness! Completions provider now checks if directories exist before calling
walkSyncon them, which prevents errors and subsequent empty responses if any directory is missing. This is good because Ember doesn't actually require that you have a/helpersor/transformsdirectory. Additionally many pods applications probably won't have/routes,/components, or/templatesdirectories. Until now, not having any of these directories prevented any completions being returned at all. - Updated
walk-syncdependency (new version adds type definitions). - Minor refactor of integration tests
Tests added, WIP tag removed. @Turbo87 Can you review this please, when you get a chance?