Marko
Marko Marko Marko Marko

Marko, a friendly (and fast!) UI library from eBay that makes building web apps fun.

Marko is a declarative, HTML-based language designed to make building web apps fun. Marko is utilized for creating dynamic and reactive user interfaces.

The principal functionalities and features of Marko are:

Core Language and Architecture

  • HTML Re-imagined: Marko extends standard HTML, meaning almost any valid HTML is valid Marko, but it enables building modern applications in a declarative way.

  • Familiarity: It is familiar to developers who know HTML, CSS, and JavaScript.

  • Scalability: It is scalable, supporting everything from simple HTML templates to powerful components as needed.

  • Trust/Usage: It is trusted, powering high-traffic, production-grade websites such as eBay.com.

Performance and Optimization

  • High Performance: Marko is performant, featuring streaming, resumable capabilities, an optimizing compiler, and a tiny runtime.

  • Faster First Paint (Streaming): It streams content to users as soon as it is ready, avoiding the wait for client-side JavaScript bundles or data requests to start rendering. HTML, assets, and images are loaded as quickly as possible, with asynchronous content loading finishing as it completes.

  • Granular by Design: The architecture is designed to be lean by default and fast. It ships only necessary code, skipping hydration and stripping unused code at the sub-template level, offering unrivaled performance on any device or network.

  • Environment Optimization: Marko compiles templates to produce optimized, environment-specific output.

    • It generates Streamed HTML for the server.

    • It generates Reactive DOM for the browser.

    • This results in faster loads and smaller bundles.

Developer Experience and Tooling

  • Typescript Support: Marko has built-in TypeScript support.

  • Strong Type Inference: It provides strong type inference that works across templates and components.

  • Full Editor Features: Editors receive full language features, including autocompletion, jump-to-definition, syntax highlighting, and clean formatting.

  • Quality Assurance: The platform helps developers build confidently, catch errors early, and write better code, faster.

  • Built-in Tags: It supports built-in HTML tags (like <div>) and core <script> tags, providing access to essential DOM methods like addEventListener, animate, append, appendChild, and focus.