Atom Packages Directory

a package directory for a text editor of the 21st Century

Autocomplete Php

Install with:
    apm install atom-autocomplete-php
  

atom-autocomplete-php

Join the chat at https://gitter.im/Peekmo/atom-autocomplete-php

atom-autocomplete-php provides autocompletion for the PHP language for projects that use Composer for dependency management. What cool things can you expect? * Autocompletion of class members, built-in constants, built-in PHP functions, … * Autocompletion of class names and automatic adding of use statements where needed. * Alt-clicking class members, class names, etc. to navigate to their definition. * Annotations in the gutter for methods that are overrides or interface implementations. * Tooltips for methods, classes, etc. that display information about the item itself. * IntellJ-style variable annotations /** @var MyType $var */ as well as /** @var $var MyType */. * Shortcut variable annotations (must appear right above the respective variable) /** @var MyType */. * …

What do I need to do to make it work?

Currently the following limitations or restrictions are present: * You must use Composer for dependency management. * You must follow the PSR standards (for the names of classes, methods, namespacing, etc.). * You must write proper docblocks for your methods. There currently is no standard around this, but we try to follow the draft PSR-5 standard (which, in turn, is mostly inspired by phpDocumentor’s implementation). Minimum requirements for proper autocompletion: * @return statements for functions and methods. * @param statements for functions and methods. * @var statements for properties in classes. * (Type hints in functions and methods will also be checked.)

Some features may or may not work outside these restrictions. Composer is primarily used for its classmap, to fetch a list of classes that are present in your codebase. Reflection is used to fetch information about classes.

The package also requires a one time setup, To configure the plugin, click on “package” in your preferences, and select “settings” on atom-autocomplete-php plugin.

You can test your configuration by using a command (cmd - shift - p) : Atom Autocomplete Php : Configuration

Linux

Configuration  

Windows (WAMP and ComposerSetup)

Settings  

CMS integration

 Framework integration

What Does Not Work?

Won’t Fix (For Now)

Conflicts

What’s Next & Contributing

Keep in mind that this plugin is under active development. If you find a bug, please, open an issue with more information on how to reproduce. Feel free to contribute ;)

A screenshot of your spankin' package

Keywords: php, composer, autocomplete Suggest keywords
Fork me on GitHub