Smart Component File Structure & Auto-Registration
Any Single-File Component placed inside components/custom/ or components/registered/ is instantly auto-detected and registered by the Conpacts Registry Engine without requiring manual registration hooks.
1. The Core Component Folders
All active components on your site reside within the protected components/ directory. The engine splits active components into two auto-registered folders:
conpacts/
├── bootstrap.php # Protected: Custom initialization
├── conpacts.php # Core loader
├── manifesto.md # Architecture guidelines
├── components/
│ ├── custom/ # [AUTO-REGISTERED] 100% bespoke custom components
│ │ ├── assets/ # Isolated custom scripts & styles
│ │ │ ├── scripts.js
│ │ │ └── styles.css
│ │ └── my-custom-widget.php
│ │
│ └── registered/ # [AUTO-REGISTERED] Active library bundle components
│ ├── about-stats-arcturus.php
│ └── feature-bento-betelgeuse.php
│
└── extensions/
├── library/ # READONLY: Upstream bundle warehouse (Conturalis Cloud)
│ └── components/
│ ├── arcturus/
│ ├── betelgeuse/
│ └── canopus/
└── third-party/ # Protected: External community packages
└── components/
2. The Two Auto-Registration Directories
conpacts/components/custom/(Auto-Registered Custom Scope):This is the dedicated folder for unique, bespoke components built specifically for your client or project. Any component placed here is automatically scanned, assigned the
customscope, and placed under theconpactsblock category. It also includes an isolatedassets/folder for custom CSS and JS.conpacts/components/registered/(Auto-Registered Library Scope):This is the active directory for curated Conturalis library components. When a component from an upstream bundle is placed in this folder, the engine automatically registers it and assigns the
libraryscope, allowing it to seamlessly receive upstream updates.
3. How to Activate and Connect Library Components
Curated component bundles (such as Arcturus or Betelgeuse) are stored inside extensions/library/components/. To activate a library component and keep it connected to upstream updates:
- Copy to
registered/: Copy the component file fromextensions/library/components/{bundle}/intoconpacts/components/registered/. - Update DocBlock Status: Change the metadata comment from
Status: StoredtoStatus: Registered. - Automatic Upstream Sync: Because the component lives in
registered/and keeps its bundle name (e.g.,cts-accordion-arcturus), it remains connected to receive non-destructive upstream template and logic updates during framework updates.
4. Decoupling with Custom Forks
If you need to make destructive or heavy modifications to a library component and want to disconnect it permanently from upstream updates:
- Move the file into
conpacts/components/custom/instead ofregistered/. - Append the
-custom-forksuffix to the filename and Nowdoc JSON name (e.g.,accordion-arcturus-custom-fork.phpand"name": "cts-accordion-arcturus-custom-fork"). - Set
"scope": "custom"in the JSON header.