{"id":23679182,"url":"https://github.com/laravel-ls/laravel-ls","last_synced_at":"2025-04-06T14:10:32.853Z","repository":{"id":270221688,"uuid":"899644053","full_name":"laravel-ls/laravel-ls","owner":"laravel-ls","description":"Laravel Language Server written in go.","archived":false,"fork":false,"pushed_at":"2025-03-12T13:47:20.000Z","size":176,"stargazers_count":134,"open_issues_count":0,"forks_count":5,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-03-30T13:07:46.725Z","etag":null,"topics":["emacs","laravel-framework","lsp-server","neovim","php","zed"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/laravel-ls.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"pnx"}},"created_at":"2024-12-06T17:39:53.000Z","updated_at":"2025-03-28T22:01:24.000Z","dependencies_parsed_at":null,"dependency_job_id":"096b4bb2-2b1d-4331-97b1-b4dac4a07cae","html_url":"https://github.com/laravel-ls/laravel-ls","commit_stats":null,"previous_names":["laravel-ls/server"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/laravel-ls%2Flaravel-ls","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/laravel-ls%2Flaravel-ls/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/laravel-ls%2Flaravel-ls/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/laravel-ls%2Flaravel-ls/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/laravel-ls","download_url":"https://codeload.github.com/laravel-ls/laravel-ls/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247492513,"owners_count":20947544,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["emacs","laravel-framework","lsp-server","neovim","php","zed"],"created_at":"2024-12-29T17:32:08.627Z","updated_at":"2025-04-06T14:10:32.829Z","avatar_url":"https://github.com/laravel-ls.png","language":"Go","funding_links":["https://github.com/sponsors/pnx"],"categories":["Go"],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003eLaravel-ls\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n    Laravel Language Server written in go.\n    \u003cbr /\u003e\n    \u003ca href=\"#about\"\u003eAbout\u003c/a\u003e\n    |\n    \u003ca href=\"#features\"\u003eFeatures\u003c/a\u003e\n    |\n    \u003ca href=\"#install\"\u003eInstall\u003c/a\u003e\n    |\n    \u003ca href=\"#build\"\u003eBuilding\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/laravel-ls/laravel-ls/actions/workflows/test.yml\"\u003e\n        \u003cimg src=\"https://github.com/laravel-ls/laravel-ls/actions/workflows/test.yml/badge.svg\" /\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n## About\n\nLaravel-ls is a tool that enhances your text editor or IDE with\npowerful features specifically designed for [Laravel](https://laravel.com) projects.\n\nBy implementing the [Language Server Protocol (LSP)](https://microsoft.github.io/language-server-protocol/),\nLaravel-ls seamlessly integrates with any LSP-compatible editor, bringing advanced capabilities\nsuch as intelligent auto-completion, navigation to definitions, real-time diagnostics, and more.\n\nAlthough still in its early development stages, Laravel-ls aims to provide a\nstreamlined and efficient development experience tailored to the Laravel framework.\n\n## Features\n\nList of done and planned features of the language server.\n\n### Views\n\n```php\nview('home')\nRoute::view('/user/profile', 'user.profile')\n```\n\n- [x] Hover information shows view template path.\n- [x] Go to definition opens the template\n- [x] Auto-complete existing template names\n- [ ] Auto-complete for existing arguments present in the template\n- [x] Diagnostics for template files that do not exists\n- [ ] Code action to create view file that do not exists.\n\n### Environment\n\n```php\nenv('APP_NAME');\nEnv::get('APP_NAME');\n```\n\n- [x] Hover information shows actual value from `.env` file\n- [x] Go to `.env` file and key location\n- [x] Auto-complete for defined keys.\n- [x] Diagnostics for non defined keys.\n- [x] Code action to create missing key\n\n### Config\n\n```php\nconfig('app.name')\nconfig()-\u003estring('app.name')\nconfig()-\u003egetMany(['app.name'])\nConfig::get('app.name')\nConfig::getMany(['app.name'])\n```\n\n- [x] Hover information shows actual value.\n- [x] Auto-complete for defined config keys\n- [x] Go to config file and value location from key\n- [x] Diagnostics for non defined config keys.\n\n### Application bindings\n\n```php\napp('db.connection')\napp()-\u003emake('db.connection')\napp()-\u003ebound('db.connection')\napp()-\u003eisShared('db.connection')\napp()-\u003emake('db.connection')\napp()-\u003ebound('db.connection')\napp()-\u003eisShared('db.connection')\n```\n\n- [x] Hover information shows value.\n- [x] Auto-complete for defined bindings\n- [x] Go to location where binding is defined\n- [x] Diagnostics for non defined bindings\n\n### Assets\n\n```php\nasset('main.css');\n```\n\n- [x] Auto-completion\n- [x] Go to asset file\n- [x] Diagnostics for non existent assets\n\n### Blade components\n\n```html\n\u003cx-component.name /\u003e\n\u003cx-component name=\"dynamic-component\" /\u003e\n```\n\n- [ ] Hover information show path to the component\n- [ ] Auto-complete existing components\n- [ ] Auto-complete arguments defined in the component\n- [ ] Diagnostics for components that do not exists.\n- [ ] Code action to create missing components\n\n## Other features on the horizon\n\n- Livewire support\n- Inertia support\n- Eloquent support\n- Jump to test file from class.\n\n## Install\n\nThe program can be installed via go:\n\n```sh\ngo install github.com/laravel-ls/laravel-ls/cmd/laravel-ls@latest\n```\n\nAnd if you have added [GOPATH](https://pkg.go.dev/cmd/go#hdr-GOPATH_environment_variable) to your shell's `PATH`. You should be able to just run the server with:\n\n```sh\nlaravel-ls\n```\n\nSee the official documentation of [go install](https://go.dev/ref/mod#go-install)\n\n## Build\n\nTo build the project you need golang version `1.22` or later, `make` and a c compiler.\n\nWhen the dependencies are met, running `make` will compile and produce the\nbinary `build/laravel-ls`.\n\n## Configure\n\n### Neovim\n\nThe LSP server can be started like any other server via `vim.lsp.start` and an auto-command.\n\nJust change the path to the correct directory on your filesystem\n\n```lua\nvim.api.nvim_create_autocmd(\"FileType\", {\n    pattern = { \"php\", \"blade\" },\n    callback = function ()\n        vim.lsp.start({\n            name = \"laravel-ls\",\n            cmd = { '/path/to/laravel-ls/build/laravel-ls' },\n            -- if you want to recompile everytime\n            -- the language server is started.\n            -- Uncomment this line instead\n            -- cmd = { '/path/to/laravel-ls/start.sh' },\n            root_dir = vim.fn.getcwd(),\n        })\n    end\n})\n```\n\n## Author\n\nHenrik Hautakoski \u003chenrik@shufflingpixels.com\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flaravel-ls%2Flaravel-ls","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flaravel-ls%2Flaravel-ls","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flaravel-ls%2Flaravel-ls/lists"}