All notable changes to the "php-namespace-resolver" extension will be documented in this file.
- init
- fix stupid issue in 002
- fix incorrect ns for some files
- ns resolve should work with external/vendor packages now too, any issues plz open a ticket
- fix error msgs
- fix double back slash in namespace
- make sure the command panel entries only shows up in php files
- fix import class before declare statements
- cleanup
- expose some functionality for other extensions to use
- support getting file namespace from just the uri
- fix giving error when file namespace if not pre-declared under
composer.json
- fix a regression in 0.1.6
- use ts instead of js
- better api
- import all will now handle (traits, property promotions, interfaces)
- better api using php-parser
- remove class import when using expand command
- show error when importing a class that has a name being used as an alias
- fix not showing all available namespaces for selected class
- use
fs.readFileinstead ofvscode.openDocument
- add new configs
- configs are now separated into categories, plz update your settings
- try to load php builtin namespaces dynamically & fall back to hardcoded classes when not possible
- if use statement already exists, no changes will be made
- support importing/expanding class FQN when its called with a partial FQN ex.
Rules\Password+use Illuminate\Validation\Rules; - you will get an error msg if a use statement already exists with a similar class name of what u r trying to import ex.
use Illuminate\Facade\Password;+ importing ex.Rules\Password
- fix not parsing of other types than class
- fix giving error when opening invalid workspace
- fix not generating namespace
- add new option
namespaceResolver.forceReplaceSimilarImportsto replace similar class import instead of keeping both (old & new)
- group menu items to submenu to save space in the context menu
- add new configs
namespaceResolver.removePath,namespaceResolver.useFolderTree,namespaceResolver.namespacePrefix - you we now generate namespaces based on folder hierarchy if project doesn't have a
composer.jsonfile &namespaceResolver.useFolderTreeistrue
- fix incorrect check for already imported classes with similar name
- fixes for
importAll - we now also check for type hints & return types for classes to import
- show output panel when phpcommand fails
- allow the extension to work regardless of parsing errors
- config
excludeis now array instead of string for better readability - classes are now expanded by default on import
- fix double importing of namespaces
- fix adding duplicate imports in
importAll importAllnow also include static calls with fqn class- fix removing the imported class and showing that it exists afterwards
- add new cmnd
Update File Type Name By File Nameinstead of manually changing the name - show correct msg for the
importAll - remove
-lockup from the class name search
- add a way to escape importing a class but continue importing others for
importAll& get a msg which one was ignored - fix trying to import a class that is already imported as an alias
- fix not resolving the correct namespace if you have similar auto-loaded paths in
composer.json
- fix adding namespace before declare statement
- add new command to copy current class fqns
namespaceResolver.copyNamespace
- a couple of fixes
- add support for importing docblock classes through
importAll
- remove the sorting cmnd, user should be using linters instead
- remove
keybindings, user is free to assign the key he wants - change cmnd name
update_file_type_by_nametoupdateFileTypeByName - add new cmnd to copy the class fqcn
copyTypeFQCN
- replace
namespaceResolver.copyNamespacewithnamespaceResolver.copyTypeFQCN - add options for how to copy the fqcn
- fix not able to copy the fqcn of the current class
- fix not importing in the correct place
- fucken typo