Gleam Snippets
Gleam snippets for Zed IDE. A collection of Gleam snippets to improve your development speed.
How to install
With Forge Super installed, the button above opens the app on this extension, where you press Install. Nothing is installed until you do.
You can also open the Extensions panel in the app and search for Gleam Snippets. The extension's id is gleam-snippets.
Don't have Forge Super yet? Download it here.
README
From the extension's repository, written by its authors and not by Mentenaz. See the source.
Gleam Snippets for Zed IDE
A collection of Gleam snippets for the Zed IDE that you might be used to from other editors.
Features
This extension provides a comprehensive set of snippets for Gleam development, including:
- Package and import declarations
caseanduseexpressionsletandconstassignment expressions- Public, private, test and anonymous function declarations
- Type declarations
- Pipes
- And much more!
Installation
Method 1
- Go to Extensions menu in Zed IDE
- Search for "gleam-snippets"
- Click "Install"
Method 2
- Clone this repo:
git clone https://github.com/BlueBlizzardd/gleam-zed-snippets
- Go to Extensions menu in Zed IDE
- Click "Install Dev Extension"
- Select the folder you cloned
Usage
Start typing the snippet prefix in a Gleam file and press Tab to expand the snippet.
Available Snippets
| Prefix | Description |
|---|---|
pub / pub fn | Public function |
fn | Private function |
test | Test function |
af | Anonymous function |
let | Let assignment |
leta | Let assert assignment |
const | Const assignment |
pub / pub const | Public const assignment |
use | use expression |
case | case expression |
type | Type declaration |
pty / pub type | Public type declaration |
pexfn / pub external / pub external fn | Public external function declaration |
im | Import |
im. | Import unqualified |
p / |> | Pipe |
# | Tuple |
bl | Block |
seq / should | Should equal |
strue / should / should.b | Should be true |
sfalse / should / should.b | Should be true |
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
License
This project is licensed under the GNU General Public License v3.0 - see the LICENSE file for details.
Author
Eduardo Juliao - ejuliao9@gmail.com