DEV Community

Drash Land
Drash Land

Posted on

Drash v1.3.0 Release Notes

Drash v1.3.0 was released! This release contains a few new features, performance improvements, and bug fixes. Here are some highlights:

New Features

Front-end TypeScript Support

With the help of Drash's ServeTypeScript middleware, you can write front-end TypeScript. Yup, you read that correctly! Front-end TypeScript.

Here's how it works:

  1. You give this middleware TypeScript files to compile when your Drash application starts up.
  2. When your application is starting up, the middleware compiles the files into JavaScript and saves the JavaScript in memory -- ready to be used when your application is running.
  3. When a request is made to a TypeScript file from your front-end, the middleware sends back the compiled JavaScript -- allowing your browser to execute it.

Since the TypeScript files are compiled and cached when your application starts up, your application stays quick to respond to requests.

Want to scale your front-end using TypeScript with a single tool? Check out the ServeTypeScript tutorial.

Create React Apps

Drash comes with a basic tool to help you quickly create a Drash application with everything working out of the box. In the past, we only supported one front-end framework: Vue. Now, you can create both Vue and React apps.

Want to build a Drash + React app? Get started with Drash's Create App script here.

Improved Templating System

Drash has been reworked to support template engine middleware. Specifically, its very own Tengine middleware. This piece of software allows your Drash application to render HTML pages with the template engine of YOUR choice. If you don't have a preference, it also comes with a default template engine called Jae and it's super easy to use.

Want to render HTML in an easy, scalable fashion? Check out the Tengine tutorials.

Virtual Paths

Virtual paths allow a project's file structure to be more flexible. It also helps prevent you from having to give users access to parts of your system just so you can serve static assets such as CSS and JS files. We want you to keep your application secure, so we have added virtual paths -- allowing you to control what URLs map to what folders in your project(s).

Want to add virtual paths to your Drash application? Check out the tutorial.

Performance Improvements

We realized during our time hammering on Drash that it slowed down when the number of resources (similar to controllers in the MVC pattern) increased. Each resource increased the size of the cache used for resource lookups. This also increased the time it took Drash to match a resource with a given request. We figured out where Drash's performance decreased and restructured the way it looks for resources. Now, Drash keeps its performance up when loaded with 1 resource or even 10,000 resources. For more information about this performance issue, you can check out the discussions on the GitHub pull request.


View the Drash project here.

More information on this release can be found at https://github.com/drashland/deno-drash/releases/tag/v1.3.0.

Want to contribute to the Drash Land projects? View our "Good First Issues" here.

Latest comments (0)