EdgeJS
Edge is a feature-packed template engine for Node.JS that AdonisJS utilizes out-of-the-box. It comes with support for conditionals, looping, partials, layouts, components, and so much more.
From The Feed
-
A Simple Framework Based on Edge.js
Hi everyone, I’ve just released Laman.js, a simple framework that adds file-based routing with Express on top of Edge.js and integrates Vite for easier development. I’ve also built LamanHub, a hosting platform where you can deploy Laman.js ...
Read more
Lessons.
Vite and Our Assets
In this lesson, we'll learn how Vite is integrating into our EdgeJS views to serve our JavaScript and CSS files.
Linking Between Routes
In this lesson, we'll learn how we can link between the routes we have defined in our application. We'll also learn about the importance of HTTP Method verbs and resources to standardize our route definitions.
Rendering a View for a Route
In this lesson, we'll learn how we can use the EdgeJS Template Engine to render HTML views and send them back as the response for our routes. We'll also see how we can pass dynamic data into our views from our route handler.
Form HTTP Method Components
In this lesson, we'll create helper HTTP Method form components, further simplifying our method spoofing by allowing us to just chain the desired method off our form component.
Form Component Method Spoofing
In this lesson, we'll add simplified HTTP Method Spoofing functionality to our base form component. With this simplified functionality all we'll need to do is specify the desired HTTP Method to the method prop and it'll add it to our URL.
Form Utility Component
In this lesson, we'll start a form utility component. This component will allow us to create one central location where we can maintain our forms and provide additional functionality like simplified method spoofing.
Bordered, Active Bordered, and Plain Variants
In this lesson, we'll split out three different variants from the accordion item we made in the last lesson. We'll create bordered, active bordered, and plain accordion items.
Identifying Accordion Items
In this lesson, we'll add the ability to have more than one item on a given accordion by creating a new accordion item component.
Starting Our Accordion
In this lesson, we'll start our accordion component and gain an understanding of how to handle uniquely identifying components that may appear multiple times on a single page via the AlpineJS magic id utility.
Dismissible & Self Destructing Alerts
In this lesson, we'll focus on adding interactivity to our alerts by making them both conditionally dismissible and self-destructable.
Inverse Alert Style & Cascading Slots
In this lesson, we'll add our alert's inverse styling by extending our base alert. We'll also see how to cascade slots passed into our inverse alert to our extended base alert.
Adding Conditional Icon, Headline, and Message Content
In this lesson, we'll make our alert's icon, headline, and message completely optional. We'll also allow our icon to be provided via slot and our headline and message via prop or slot.
Adding Alert Variants
In this lesson, we'll focus on adding a light, dark, blue, green, red, and yellow variant option to our base alert.
Creating Our Base Alert
In this lesson, we'll create our base alert to serve as our building block for our content, variant, and style options. We'll also fix a pseudo-selector issue.
Adding Button Inverse and Outline Styles
In this lesson, we'll add two new button style options, inverse and outline. Both styles will extend off the work we did with our base button to keep all functionality in one concise location
Adding Button Variants
In this lesson, we'll add variant options for our base button. These will provide light and dark options as well as stateful coloring blue, green, red, and yellow.
Adding Button Size Options
In this lesson, we'll add four size options to our base button large, base, small, and extra small. These sizes will then automatically be available as we add our button variants and styles.
Adding Interactivity to our Button
In this lesson, we'll add extendable interactivity to our button using AlpineJS. We'll also walk through a demonstration of how we can utilize event propagation in AlpineJS to our advantage.
Creating Our Base Button
In this lesson, we'll create our base button component which al our other button styles will derive from. It'll be in charge of building our classes, adding interactivity, and more.
Main Slot, Named Slots, and Slot Scopes
In this lesson, we'll learn all about the main slot, how to define and use named slots, as well as passing state information from within our components to our slots using slot scopes.
Showing 41 to 60 of 87 results