How wiris/html-integrations works
Main Components Identification
• Devkit & Core Libraries: Identify the central reusable functionality in packages such as the devkit (packages/devkit) and core integrations which are reused by the individual editor plugins.
• Editor Plugins: Clearly list separate packages for CKEditor4, CKEditor5, Froala, TinyMCE (versions 5, 6, 7), Generic, Viewer, etc. (see folders inside packages such as packages/ckeditor4, packages/ckeditor5, packages/froala, packages/tinymce*, packages/generic, packages/viewer, and packages/wordpress).
• Demo Applications: Represent the “demos” folder, which holds multiple demo implementations (HTML demos, Vue demos, etc.) for quick testing and integration examples.
• Testing Infrastructure: Include the Cypress test suites (cypress directory and its subfolders) showing end-to-end tests, sandbox, smoke, and validation tests.
• Documentation & Developer Guides: Incorporate the “docs” directory (including ADRs, contributing guidelines, development instructions) which illustrates the project’s architectural decisions.
• CI/CD & Build Configuration: Represent the GitHub workflows (.github/workflows) for automated tests, deployments, publishing packages, and other build scripts (e.g. babel.config.js, webpack.config.js files across various packages).
• Configuration & Infrastructure: Show configuration files (nx.json, tsconfig.*, etc.) and environment-specific files like Terraform configs for AWS which are in the “terraform” folder.
Relationships and Data Flow
• CI/CD tools (GitHub workflows, Cypress tests, and build scripts) as a separate block that interacts with all other components, enforcing the build and test pipelines.
Architectural Patterns and Design Principles
• Monorepo Structure: Highlight that the structure uses an NX (or similar) monorepo setup to manage multiple interdependent packages.
• Separation of Concerns: Emphasize that different integrations are modularized into distinct packages while sharing a common devkit.
• CI/CD & Automated Testing: Stress the automated testing and deployment pipelines; represent how changes are first run through the Cypress tests and then are built and deployed via GitHub workflows.
• Dependency Management: Indicate that the build scripts, configuration files (babel, webpack, tsconfig) and package.json files keep the dependencies clear and ensure consistency across all integrations.
• Core Integration Layer: Central block labeled “MathType Devkit / Core” including references to packages/devkit, common libraries, and shared configuration.
• Individual Plugin Modules: Separate blocks for “MathType for CKEditor4”, “MathType for CKEditor5”, “MathType for Froala”, “MathType for TinyMCE (5/6/7)”, “MathType Generic”, “MathType Viewer”, and “MathType for WordPress” (if applicable).
• Infrastructure & Configuration: Components for monorepo configuration with Nx (nx.json), type configurations (tsconfig files), and build scripts (webpack, babel) as supporting layers.
• External Dependencies: An “External Services” block for the npm registry and external editors (CKEditor, Froala, TinyMCE) to indicate consumption points.
• Every file or configuration cluster from the repository that impacts system architecture (CI/CD pipelines, demos, build scripts) is represented, either directly or in an aggregated “Infrastructure” or “Configuration” component.