# Glass-easel: New Weixin Mini Program Component Frames

Glass-easel is the core implementation of the Weixin Mini Program component framework.It is essentially a JavaScript componentized interface framework for componentized, defined interface development.

Glass-easel is a rewrite of the old Weixin Mini Program component framework, maintaining compatibility with the old Mini Programs component framework features, and adding some new features. It does not depend on the Mini Program environment and can run independently on the web or other JavaScript environment.

# Main characteristics

Glass-easel allows the same component code to run in different environments such as the web, Weixin Mini Program, etc.

The backend is an important concept of glass-easel, which represents the operating environment of the component system.When running on the web, the backend is the browser's DOM interface.When running in the Weixin Mini Program environment, the backend is the Mini Program environment interface.This allows (back-end unrelated) component code to run in different environments.

Glass-easel is fully equipped with custom component-related features such as component templates, communication and events, life cycles, and more. In addition, glass-easel has implemented some useful new features and better TypeScript support.

Glass-easel uses a single-component node tree update algorithm (largely following the update algorithm of the older Weixin Mini Program component framework) to achieve a balanced performance and is suitable for highly componentized development.





glass-easel 组件框架在 GitHub 上开源,代码和更详细的文档、示例等可以在 GitHub 上找到。

# Appropriate guidelines

The glass-easel adaptation guide lists some of the logic that needs to change compared to the existing component framework_exparser_, which can be used to migrate an existing Weixin Mini Program to a new framework or to quickly understand the differences between new and old frameworks.