ccmjs is a lightweight JavaScript framework that implements the Client-side Component Model (CCM) — an architecture for building modular, reusable, and dynamically composed web applications.
Unlike typical frontend frameworks, ccmjs operates entirely at runtime and does not require build tools, bundlers, or compilation.
Components can be loaded, configured, and composed dynamically at runtime — even across different framework versions.
Include ccmjs:
<script src="https://ccmjs.github.io/framework/ccm.js"></script>
Start a component:
ccm.start(component, config, document.body);
The Client-side Component Model (CCM) is an architectural approach for building web applications from independent, reusable components that are composed at runtime.
Each component
This allows applications to be composed from independently evolving components while maintaining compatibility across versions.
ccmjs provides the reference implementation of this model in JavaScript.
<!DOCTYPE html>
<meta charset="UTF-8">
<body>
<script src="https://ccmjs.github.io/framework/ccm.js"></script>
<script>
const component = "https://ccmjs.github.io/quiz/ccm.quiz.mjs";
const config = {
feedback: true,
questions: [
{
text: "Does this example work?",
input: "radio",
answers: [
{ text: "Yes", correct: true },
{ text: "No" }
]
}
]
};
ccm.start(component, config, document.body);
</script>
This loads the quiz component dynamically, instantiates it, and renders it into the page.
| Function | Purpose |
|---|---|
ccm.load() |
Load resources dynamically |
ccm.component() |
Register or load components |
ccm.instance() |
Create component instances |
ccm.start() |
Create and start component instances |
ccm.store() |
Create datastore accessors |
ccm.get() |
One-time data retrieval |
<script src="https://ccmjs.github.io/framework/ccm.js"></script>
ccm.start(componentURL, config, element);
That’s it — the framework performs the full lifecycle automatically:
Most frontend frameworks assume
ccmjs instead focuses on runtime composition.
Components can be
This enables
Full documentation is available in the ccmjs Wiki.
ccmjs is released under the MIT License.