scohen
Lexical
Lexical is a next-generation language server for the Elixir programming language.
Features
- Context aware code completion
- As-you-type compilation
- Advanced error highlighting
- Code actions
- Code Formatting
- Go To Definition
- Completely isolated build environment
What makes Lexical different?
There are a couple things that lexical does differently than other language servers. Let’s look at what separates it from the pack.
Architecture
When lexical starts, it boots an erlang virtual machine that runs the language server and its code. It then boots a separate virtual machine that runs your project code and connects the two via distribution. This provides the following benefits:
- None of lexical’s dependencies will conflict with your project. This means that lexical can make use of dependencies to make developing in it easier without having to “vendor” them. It also means that you can use lexical to work on your project, even if lexical depends on your project.
- Your project can depend on a different version of elixir and erlang than lexical itself. This means that lexical can make use of the latest versions of elixir and erlang while still supporting projects that run on older versions.
- The build environment for your project is only aware of your project, which enables as-you-type compilation and error reporting.
- In the future, there is a possibility of having the lexical vm instance control multiple projects
Lexical 0.4.0 Has been released!
Get it here: Release v0.4.0 · lexical-lsp/lexical · GitHub
Github: GitHub - lexical-lsp/lexical: Lexical is a next-generation elixir language server · GitHub
The main thrust of v0.4 is hover support and quality of life improvements. Now, when you hover over a module or function, you’ll see relevant documentation, types and parameters. We’ve also spent a lot of time working on completions in #410, which makes them more consistent, fixes some bugs in certain language clients (like eglot adding an extra @ when completing module attributes), and greatly improves their feel in vscode.
Additionally, quite a few of the changes in this PR were about laying the groundwork for our indexing infrastructure, which will debut in the next version. But fear not, this version has indexing disabled.
I want to thank @zachallaun and @scottming for all their hard work on this release. They’ve made lexical faster, more friendly and have removed a bunch of bugs!
Highlights include:
- Document hover for functions and modules
- Improved boot scripts
- Automatically updating nix flake. Thanks, @hauleth
- Helix editor integration. Thanks @philipgiuliani
- .heex integration
- Massively improved completions (Check out the PR, it’s too big to summarize)
Bugs fixed:
- Longstanding unicode completion / editing bugs slain. Unicode works perfectly now.
Trending in Announcing
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ai
- #ecto-query
- #elixirconf-us
- #blog-post
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #elixirconf-eu
- #api
- #forms
- #metaprogramming
- #hex











Showing Posts 78 to 69- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
scohen
It’s coming shortly, there’s already a pr out.
dimitarvp
OK, we’ll have to wait a little bit more for Elixir 1.18. Just tried Lexical and it said it’s not working with 1.18 yet.
Terbium-135
What a nice improvement it is!
But why Lexical wasn’t like this right from the start??
Just kidding
Thanks for all your work!
BartOtten
Congratz with the release!
dimitarvp
Heya, I have been extremely busy in every area of life for like 6-7 months now and have stopped following but things are gradually calming down and I seriously want to start using Lexical full-time.
Was the workspace symbols feature added? I seem to recall you said it was? Furthermore, is Lexical working with Elixir 1.18 / Erlang 27.x?
scohen
Lexical 0.7.2 has been released
It includes fixes for some long-standing performance issues, and improved support for editing configuration files.
Lexical is now VERY snappy. Enjoy!
scohen
Lexical 0.7 Has been released!
We’re releasing 0.7 so we can support Elixir 1.17 and Erlang 27. However, those users on Erlang 27 will experience large increases in the amount of memory Lexical takes up due to this bug. When that bug is fixed, we’ll push out another release that will detect the newer version of Erlang and things should go back to normal.
There are a lot more features and bugfixes too, like “Add Alias” and “Organize Aliases” code actions. Check out the full release notes here
craig
I just started trying lexical but I wanted to say - thanks for having vim + ALE support! Was very easy to get it up and running
dimitarvp
It’s a better option than doing live grep. Not hugely better but reduces the signal-to-noise ratio enough for it to be perceptibly better.
(Also if you are going to flatter somebody, don’t misspell their name!
)
scohen
well, now i’m using workspace symbols all the time.