Skip to content

Latest commit

History

8 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

UntitledModuleFramework (UMF)

UMF is a lightweight javascript framework written mostly in vanilla Javascript. It provides a few fundamental features that a programmer would ask from a framework, together with extensibility to provide your own features.

Installation

Configuration

Defining modules

exportconstmodules={'moduleIdentifier': {'component': componentName,'singleton': shouldBeSingleton,'defaults': componentDefaults},}

Initializing the kernel

import{polyfills}from'./core/polyfill.js';import{kernelBuilder}from'./core/kernel.js';document.addEventListener('DOMContentLoaded',()=>{polyfills();// start the kernel with the known modulestry{constkernel=kernelBuilder(modules)}catch(e){console.error(e)}});

Starting modules

try{constkernel=kernelBuilder(modules)// find all modules that are currently required and start themdocument.querySelectorAll('[data-js-module]').forEach(el=>{kernel.startModule(el.getAttribute('data-js-module'),{...el.dataset})});}catch(e){console.error(e)}

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

About

A simple module framework built with native javascript

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages