npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

uxml.js

v0.1.0

Published

UXML is a lightweight JavaScript library designed to streamline web development by reducing the reliance on embedded JavaScript within HTML files. This library empowers developers to create dynamic and interactive web elements using simple, clean, and scr

Downloads

7

Readme

Unscripted eXtended Markup Language (UXML)

UXML a lightweight, script-free component library designed specifically for web development within HTML. Whether you're a seasoned developer or new to web development, UXML simplifies the creation of interactive web applications without the need for complex JavaScript frameworks. You can create dynamic web components effortlessly without the need for any JavaScript code. With UXML, you can enhance user interfaces, handle user interactions, and build feature-rich web applications while working within the familiar HTML structure.

Features

  • Script-Free HTML UXML enables the creation of dynamic web content directly within HTML, eliminating the need for inline JavaScript.
  • Simplified Interactivity Easily add interactive features to your web pages using HTML attributes and minimal configuration.
  • Cross-Browser Compatibility UXML is compatible with modern web browsers, ensuring a consistent user experience.
  • Lightweight UXML is incredibly lightweight, weighing in 20 times less size than popular libraries like ReactJS.
  • No Virtual DOM UXML doesn't rely on a virtual DOM. This results in a more efficient and simplified rendering process.
  • Shallow Learning Curve UXML offers a shallow learning curve, making it accessible to developers of all skill levels. If you know HTML, you can start using UXML right away.

Getting Started

  1. Include the UXML library in your HTML document:

    <script src="https://unpkg.com/[email protected]/uxml.js"></script>
  2. Use UXML attributes within your HTML elements to add interactivity:

    <body $load="get:/pages" $swap="innerHTML">
      <!-- Your HTML body -->
    </body>

Basic

UXML uses a simple syntax $action="event:selector" similar on how we do a basic onclick="click()" event handler in plain HTML. This is consist of three(3) parts, a declaration $action, an assignment = and a handler "event:selector".

  • A $ sign to define/access UXML inspired by jquery
  • A action to be performed on the element inspired by angularjs
  • A event to emit an UXMLEvent or trigger an http request inspired by htmx
  • A : to separate event and selector
  • A selector to "query" HTML elements or "value" of a given event i.e. url for http request

Usage

UXML provides a range of attributes to enhance interactivity, such as $click, $submit, $load, $component and more. These attributes allow you to define behaviors without the need for JavaScript code.

<button $click="show:#hello">Show message!</button>
<div id="hello">Hello, UXML!</div>

Contributions

We welcome contributions from the community to improve UXML. If you have ideas for improvements or encounter any issues, please consider opening an issue or submitting a pull request on our GitHub repository.

License

UXML is distributed under the MIT License. Feel free to use, modify, and distribute this library in your projects.

Acknowledgments

UXML stands on the shoulders of giants, drawing inspiration from jquery, htmx, angularjs and the need for more simplified, cleaner, and maintainable web code. Their pioneering work has illuminated our path, empowering us to develop this project. We thank the open-source community for their contributions and support in making this project possible.