npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

coc-psalm

v0.12.4

Published

Psalm extension for coc.nvim

Downloads

59

Readme

coc-psalm

coc.nvim extension for Psalm language server.

"Psalm" started as a static analysis tool, but now it also has the features of a Language Server.

Install

:CocInstall coc-psalm

Note

Install psalm in your project.

composer require --dev vimeo/psalm

Required: The project must contain a psalm.xml or psalm.xml.dist file as a condition for starting "coc-psalm".

./vendor/bin/psalm --init

Configuration options

  • psalm.enable: Enable coc-psalm extension, default: true
  • psalm.disableCompletion: Disable completion only, default: false
  • psalm.disableDefinition: Disable definition only, default: false
  • psalm.disableProgressOnInitialization: Disable ProgressOnInitialization only, default: false
  • psalm.phpExecutablePath: Optional, defaults to searching for "php". The path to a PHP 7.0+ executable to use to execute the Psalm server. The PHP 7.0+ installation should preferably include and enable the PHP module pcntl. (Modifying requires restart), default: null
  • psalm.phpExecutableArgs: Optional (Advanced), default is '-dxdebug.remote_autostart=0 -dxdebug.remote_enable=0 -dxdebug_profiler_enable=0'. Additional PHP executable CLI arguments to use, default: ["-dxdebug.remote_autostart=0", "-dxdebug.remote_enable=0", "-dxdebug_profiler_enable=0"]
  • psalm.psalmScriptPath: Optional (Advanced). If provided, this overrides the Psalm server script to use, e.g. vendor/bin/psalm-language-server, $HOME/path/to/psalm-language-server, ~/path/to/psalm-language-server (Modifying requires restart), default: null
  • psalm.psalmScriptExtraArgs: Optional (Advanced). Additional arguments to the Psalm language server. (Modifying requires restart), default: []
  • psalm.enableUseIniDefaults: Enable this to use PHP-provided ini defaults for memory and error display. (Modifying requires restart), default: false
  • psalm.enableDebugLog: Enable this to print messages, default: false
  • psalm.analyzedFileExtensions: A list of file extensions to request Psalm to analyze. By default, this only includes 'php' (Modifying requires restart), default: [{ "scheme": "file", "language": "php" }, { "scheme": "untitled", "language": "php" }]
  • psalm.unusedVariableDetection: Enable this to enable unused variable and parameter detection, default: false
  • psalm.configPaths: A list of files to checkup for psalm configuration (relative to the workspace directory), default: ["psalm.xml", "psalm.xml.dist"]
  • psalm.trace.server: Traces the communication between coc.nvim and the Psalm language server, valid options ["off", "messages", "verbose"], default: off

Commands

  • psalm.restartPsalmServer: Restart Psalm Language server
  • psalm.analyzeWorkSpace: Analyze Workspace

Code Actions

Example key mapping (Code Action related)

nmap <silent> ga <Plug>(coc-codeaction-line)

Usage:

In the line with diagnostic message, enter the mapped key (e.g. ga) and you will see a list of code actions that can be performed.

Code Actions (Client side):

  • Show issue for https://psalm.dev/xxx: Open the issue url in your browser
  • Suppress all for this line

Code Actions (Server side):

  • Suppress XXX for this line

"psalm.xml" or "psalm.xml.dist" completion and linting and more...

To use it, you need to install coc-xml.

Thanks

License

MIT


This extension is built with create-coc-extension