PhpStorm 2021.1 is a major update that introduces the ability to preview for PHP and HTML files in the editor, 20+ new inspections to help prevent bugs, improvements in all subsystems, and pair programming via Code With Me. PhpStorm 2020.2 supports the OpenAPI Specifications plugin. This is a free plugin developed by JetBrains that provides completion, navigation, and validation in the OpenAPI spec files (openapi.yaml/openapi.json and swagger.yaml/swagger.json). The plugin also provides. It is a standalone installation of the complete offline installer of JetBrains PhpStorm 2020. JetBrains PhpStorm 2020 overview. JetBrains PhpStorm is a PHP programming language development environment designed based on the JetBrains IntelliJ IDEA platform and has almost all the functions of JetBrains WebStorm. Since updating to PHPStorm 2020.1 (Mac OS), Storm can no longer find any classes or packages through namespaces. As an example, here is one of my models (Laravel). As you can see most of the classes cannot be found, whether they are in the application itself, composer vendor files or (as with mongo) within a PHP extension.
PhpStorm 2020.2 is now available!
This major release includes support for PHP 8 Union Types, a new control flow engine for PHP, full GitHub pull requests workflow support right inside the IDE, a brand-new Inspection widget, OpenAPI support via a plugin, and more.
Read on to check out all the new features and significant updates, along with a ton of GIFs!
PHP 8 Union Types
PHP 8 will have so many new features that to some extent you can almost call it a new language. We’ve started to roll out support for version 8 early, and the first big feature is union types.
Union types T1|T2|...
can be used wherever types can currently be specified: arguments, properties, or return values. In this case, a variable can accept any of the listed types.
Union types have long been used in PHPDoc tags, but now they will really be checked in runtime by the interpreter itself.
Switch language level
To see all the features, you need to switch the language version to PHP 8. You can do this manually in settings under Languages & Frameworks | PHP | PHP language level.
You can also use the Alt+Enter quick-fix to switch if there is already some code with new features.
And if the PHP version constraint is specified in composer.json, PhpStorm will switch automatically.
Converting PHPDoc into native union types
You can call the Alt+Enter quick-fix on a PHPDoc tag union type to convert it to a native union type.
Remove unnecessary PHPDocs
If a PHPDoc tag contained only a type declaration, it may now be redundant and can be removed with an Alt+Enter quick-fix.
We are considering adding the ability to run this fix in the clean-up stage before commit. What do you think? Can it always be considered safe to do so?
Type validation
PhpStorm was already able to analyze types and find violations with PHPDoc tags. But with native declarations, these capabilities became much wider.
This is especially useful in complex code when violations are not obvious at first sight.
Pseudotype false
Some legacy functions may return false in the event of an error. For example, strpos()
, array_search()
, and 310 other standard functions behave this way.
In these cases, the return type could be declared as a union like int|bool
, but in fact it would never return true
. This is where the new false
pseudotype is useful.
The false
pseudotype can only be used as a part of union type. Otherwise, PhpStorm will highlight it as invalid code.
Duplicate and redundant types
Many combinations in type associations are forbidden or simply redundant. For example:
bool|false
— because false is a part ofbool
.Foo|Foo
orint|string|INT
— duplications.object|User
—object
contains everything else.iterable|array
oriterable|Traversable
—iterable
containsarray
andTraversable
.void
— can only be used in the return value and only as a standalone type.false
ornull
— only as part of the union type.
All such violations will be highlighted in PhpStorm.
Nullable types
The existing ?Type
syntax is now considered to be shorthand for Type|null
.
But you cannot use ?
in union types because it causes ambiguity.
PhpStorm provides an Alt+Enter quick-fix for this.
Type variance in inheritance
There are two rules for methods:
The type of the parameter is contravariant, which means it can be expanded.
The return type is covariant, which means you can only narrow it down.
Type order does not matter here, so Type1|Type2
is equivalent to Type2|Type1
.
Property type cannot be changed
The type of an inherited property has to match the type of the parent property, for example:
New control flow engine
By redesigning the control flow engine we were able to introduce new inspections and fix many old bugs. As a result, PhpStorm now understands code even better than before.
Here and there you may notice warning highlights from new inspections. Some of them may require your attention as potential sources of bugs, while fixing others can just make the code clearer and easier to read.
Here are some of the new inspections.
Variable is always true or false
Example in Parser.php from doctrine/orm.
Condition is always true
Example in FormValidator.php from symfony/form.
Result of instanceof is always true
Example in Logger.php from symfony/monolog-bridge.
Pseudovariable $this
will always be of type ResetInterface
, because it is higher up in the hierarchy.
Expression is always null
Example in ProcessUtils.php from symfony/process.
New action: Type Info (⌃⇧P / Ctrl+Shift+P)
You can point the caret at any expression and call this action to see how PhpStorm inferred the type. The action is available under View | Type Info or via the ⌃⇧P / Ctrl+Shift+P shortcut.
Improvements for Composer
Since version 2020.1, it has been possible to manage Composer dependencies directly in the composer.json file in PhpStorm. This release brings a few enhancements.
Phpstorm 2020.3
Support for Satis/Packagist custom repositories
If you specify a custom source in the 'repositories'
section, all packages in it will be available for autocompletion, and information about packages and versions will be cached in PhpStorm.
Code completion for multiple versions
If there are multiple versions separated by commas or by pipe (||
) symbols, PhpStorm will now handle completion correctly.
Links to homepage and sources
Each package now has links to its websites in the information popup.
Quick access to quality tools configuration
If the list of dependencies contains code quality tools that are supported in PhpStorm, there will be a wrench icon near them that will take you directly to the corresponding section of settings.
Improvements for quality tools
PhpStorm 2020.2 introduces a number of useful updates for quality tools.
Support for Docker Compose
PHP_CodeSniffer, PHP CS Fixer, and PHP Mess Detector can now be run with docker-compose.
Exclude list for PHP_CodeSniffer
If there is an 'exclude-pattern'
section in ruleset.xml
, it will now be taken into account and the specified files will not be analyzed in the IDE.
Phpstorm 2020 Key
Formatting with a remote interpreter
PHP CS Fixer and PHPCBF can be run via SSH, Docker, Docker Compose, Vagrant, and others.
Command Line Tools
All Symfony, Laravel Artisan, Drupal Drush, WP-CLI commands, and Composer scripts can be run very quickly in PhpStorm without opening the terminal.
Do this by adding the tool you want to use in the settings under Tools | Command Line Tool Support.
Then, by pressing Ctrl-Ctrl you will see the Run anything popup, in which all commands are available with autocompletion.
Starting with this release, you don’t even have to configure anything for Symfony, Laravel, and Drush. Just open the project, press Ctrl-Ctrl,
and start typing the command.
⚠️ For Laravel on macOS, the artisan
file must be executable (chmod +x artisan
).
You can now run these tools through any remote interpreter (SSH, Docker, Docker Compose, Vagrant). For example, you can quickly test your application with PHP 8 by adding a Docker Interpreter from the php:rc-cli
image.
Extract Class refactoring
Classes always look neat and clean at first. But over time, many methods and properties are often added to them. And at some point, you can find a class that is overgrown with an excess of responsibilities.
Here it can help to extract a bunch of related methods and properties into a new class. This is exactly what the new Extract Class refactoring offers.
Press Ctrl+T on a class member and select Extract class. PhpStorm will prompt you to enter the name of the new class and you can choose more methods and classes to extract.
This refactoring also works for functions.
More for PHP
New inspection: Typed property might be unassigned
If a typed property is defined but not initialized, the TypeError error will appear when trying to read it (if there is no magic __get()
). PhpStorm will highlight cases where you are reading from uninitialized properties.
New inspection: Array used only with write access
Example in SchemaTool.php from doctrine/orm.
The $pkColumns
array in gatherColumns()
method is updated but never read nor returned.
Customizing generated getters and setters
Now you can adjust the naming style by choosing between camelCase()
and snake_case()
.
The order in which getters and setters are generated is also configurable now.
Both options are available in settings under Editor | Code Style | PHP on the Code Generation tab.
Correct resolve when several projects are opened in one window
Previously, if you opened multiple projects in one window, you would often see errors about a class being defined multiple times. If you wanted to go to the definition of a class, you had to choose from multiple implementations.
This is no longer the case. Resolve and Go to declaration work as expected in PhpStorm 2020.2.
Lower priority for symbols from vendor
In the autocompletion list, priority will be given to classes from the project. Entities from a vendor
folder and PHAR files will get lower priority.
Full support for GitHub pull requests
Basic support for pull requests was introduced in PhpStorm 2018.3. Since then there have been some updates, but many actions still required switching to a browser.
In PhpStorm 2020.2 you can manage the entire pull request workflow directly in the IDE!
You can go to pull requests from the VCS | Git | View Pull Requests menu or from the toolbar or using the Alt+7 shortcut. The first thing you’ll see will be a list of the available pull requests with search and filtering options.
Clicking on a pull request will open detailed information about it – its reviewers, tags, modified files, and timeline.
You can work through the whole review flow all at once – start and request a review, comment on changes both at line level and in the whole commit, and submit the review.
Under the timeline, you’ll see the results of pre-commit and CI checks.
To merge a pull request, you previously had to create a local branch first. This is no longer required and you can now merge straight away from the UI.
OpenAPI support
The OpenAPI Specifications plugin is available for all JetBrains IDEs and works starting from this 2020.2 release. It provides highlighting, validation, and navigation in OpenAPI specification files (openapi.yaml
/openapi.json
and swagger.yaml
/swagger.json
).
It also provides the following features:
- Swagger UI integration – rendered directly in the IDE window.
- Code generation.
- Structural diff for spec files – this can help spot breaking changes.
- Gutter icons to create HTTP Client requests to endpoints.
- Autocompletion for endpoints in the HTTP Client.
- Rename refactoring – if you rename an endpoint in the spec file, it will automatically be renamed in the HTTP client request.
Add caret per selected line action
The new Add Caret Per Selected Line action creates carets at the end of each selected line, and deselects the lines. Invoke it using the shortcut Alt+Shift+G on Windows/Linux or ⌥⇧G on macOS.
Brand-new Inspection widget
The top right corner of the editor now displays a widget with the number of problems in the current file.
You can quickly jump to the next/previous problem by clicking the arrow icons. This was previously achieved with the shortcuts F2
/ Shift+F2
.
In the Inspection widget, you can choose which problems are displayed, for example only syntax errors or all problems.
Clicking on the widget will open a new Problems tool window with a list of all problems detected in the file.
Version control
Git from WSL 2
PhpStorm can now use the Git binary from WSL. Moreover, the IDE itself determines whether the WSL is installed and whether Git is available in it.
Settings are available under Preferences | Version Control | Git.
⚠️ Git will only work with WSL 2. Git from WSL 1 is unstable and may cause incorrect results for Git commands, therefore we do not support it.
Improved UI to compare branches
PhpStorm allows you to compare any branches and see which commits belong to which branch. To do this, select any branch available in the VCS | Branches popup and choose Compare with Current from the context menu.
In PhpStorm 2020.2, information about logs and commits is displayed directly in the editor. This allows more information to be placed on the screen.
Updated command dialogs
Dialogs for the merge, pull, and rebase Git commands have been redesigned and unified. Some missing options have been added and you can now see the exact Git command that will be executed.
All commands are available in the VCS | Git menu.
New action: Drop commit
Unnecessary or temporary local commits can now be removed directly from the PhpStorm log. To do this, call the context menu on a commit and select Drop Commit.
New action: Squash commits into one
It is also possible to combine several commits into one. It’s a good idea to do this to clear intermediate results from the history before creating a pull request or pushing changes.
Select multiple commits in the log and choose Squash Commits… from the context menu.
Database Tools
PhpStorm includes almost all of DataGrip’s features as standard. You can check out What’s new in Database tools for an overview from our colleagues about its new features.
Web
As usual, all the updates for WebStorm 2020.2 have also been incorporated into PhpStorm.
A full list of all the changes in this release is available in the really long release notes.
That’s all for today. Thanks for reading to the end! We’ll be happy to respond to your questions, suggestions, bug reports, and any thoughts you’d like to share in the comments.
Your JetBrains PhpStorm team
The Drive to Develop
JetBrains PhpStorm 2020 Download the latest version for Windows for free. Full standalone configuration of the JetBrains PhpStorm v2020.2.1 offline installer.
JetBrains PhpStorm 2020 review
JetBrains PhpStorm is a PHP development environment designed on the basis of the JetBrains IntelliJ IDEA platform and has almost all the features of JetBrains WebStorm. This program, like other JetBrains IDEs, provides developers with features such as advanced navigation and guidance, auto-completion of code, code quality analysis, troubleshooting and troubleshooting, and increased productivity and efficiency. Before you see the actual interface, you’ll get the handy Welcome to PhpStorm prompt. Before you can access the Welcome to PhpStorm prompt, you must go through the PhpStorm preconfiguration prompt, which allows you to select a keyboard scheme, select an IDE theme, and edit colors and fonts.
Returning to the Welcome to PhpStorm prompt, the Recent Projects pane on the left lists the projects that you have recently accessed. The Quick Start panel on the right allows you to create a new project, open an existing project, create a new project from existing files, configure how PhpStorm works, access documents and instructions, and register a copy of PhpStorm. As mentioned at the beginning of this article, PhpStorm has a lot to offer: an intelligent PHP code editor; HTML, CSS and JavaScript editor; support for all major PHP frameworks; code quality analysis; full WordPress support; Integration with VCS; zero configuration debugging; double code detector; code completion; code formatting; Twig, Blade or Smarty template engine; PHP remote interpreters; and not only. you can also download JetBrains GoLand
JetBrains PhpStorm 2020 Features
- And it can handle high level code.
- Supports database or SQL editor.
- Thanks to its use, you can get a great effect.
- It also gives very effective services.
- IntelliJ IDEA Torrent is the best code editing software.
JetBrains PhpStorm 2020 technical configuration details
- Full name of the software: JetBrains PhpStorm 2020
- Installation file name: JetBrains_PhpStorm_2020.2.1.rar
- Full configuration size: 319 MB
- Installation Type: Offline Installer / Full Standalone Install
- Compatibility Architecture: 64-bit (x64)
- The latest release version has been added: December 17, 2020
- Developers: JetBrains
System requirements for JetBrains PhpStorm 2020
Before you start downloading JetBrains PhpStorm 2020 for free, please make sure your computer meets the minimum system requirements.
- Operating system: Windows 7/8 / 8.1 / 10
- Memory (RAM): 8 GB RAM required.
- Hard Disk: 500 MB of free space required.
- Processor: Intel dual-core processor or above.
JetBrains PhpStorm 2020 for free download
Click the button below to start downloading JetBrains PhpStorm 2020 for free. It is a complete offline installer and standalone configuration for JetBrains PhpStorm 2020. It would be compatible with 64 bit windows.