Description
Two Nx libraries in core-web are dead code and should be removed. Both have zero consumers, are excluded from CI, and do not compile today.
They surfaced while working through the strict-mode rollout (epic #35932) — enabling strict on either would mean fixing type errors in code nobody uses, with zero verification signal since no CI target compiles them.
| Library |
What it is |
Superseded by |
Strict errors avoided |
libs/dotcms |
Legacy initDotCMS SDK (dotcms@0.0.21) |
@dotcms/client |
~48 |
libs/dot-layout-grid |
Legacy NgGrid layout grid (vendored angular2-grid) |
GridStack 8.4.0 in libs/template-builder |
119 |
1. libs/dotcms — legacy initDotCMS SDK
Nobody imports it — verified five ways
| Check |
Result |
| Nx project graph |
0 dependents, 0 outgoing dependencies |
@dotcms/dotcms imports across the repo |
None |
initDotCMS symbol usage |
None outside the library |
dotcms declared as a dependency in any package.json |
None |
References to libs/dotcms |
Only tsconfig.base.json:35 (alias), nx.json:227 (Jest plugin glob), README.MD:12 |
Unmaintained and broken
libs/dotcms/project.json is tagged ["skip:test", "skip:lint", "skip:build"] — CI never builds, lints, or tests it.
- Does not compile, even with
strict disabled. src/lib/api/DotApiContentType.ts:1 and src/lib/api/DotApiForm.ts:1 import from 'dotcms-models', a path alias that no longer exists (current one is @dotcms/dotcms-models) — 5 TS2307 errors regardless of strict mode.
- Last published to npm 2022-10-10. No release wiring: the
publish target points at tools/scripts/publish.mjs, which does not reference it, and no workflow invokes it.
2. libs/dot-layout-grid — legacy NgGrid layout grid
Nobody imports it — verified four ways
| Check |
Result |
| Nx project graph |
0 dependents, 0 outgoing dependencies |
@dotcms/dot-layout-grid alias usage |
Only its own definition at tsconfig.base.json:33 |
Exported symbols (NgGridModule, NgGrid, NgGridItem, NgGridConfig, NgGridPlaceholder, …) in .ts |
None outside the library |
Template usage (nggrid, ng-grid) in .html |
None |
The symbol and template searches matter here — it is a library of Angular directives, consumed from templates, so the path alias alone would not be sufficient proof.
Dead for two years, and broken
- Its last consumer was deleted in
5e75d4ddb0 (2024-08-22, "remove unused code from old template builder"), which removed dot-edit-layout-grid, dot-container-selector-layout and dot-edit-layout.service.ts from apps/dotcms-ui. Every commit touching it since is a mechanical sweep (Angular v19/v20, Nx 23, eslint 9, the inject() codemod).
- Does not compile.
src/lib/directives/NgGrid.ts:8 imports ComponentFactoryResolver from @angular/core, removed from Angular (deprecated in v13, dropped in v20+) — 2 errors present without enabling strict.
package.json declares peerDependencies of @angular/common / @angular/core at ^6.0.0 || ^7.2.0; the workspace is on Angular 21+.
- Has no
build target at all — project.json defines only test, and it is tagged ["skip:test", "skip:lint"]. Nothing compiles it, not even an inferred target.
- Never published to npm —
dot-layout-grid does not exist in the registry (version: 0.0.1). No external consumers are possible.
ng-package.json and ng-package.prod.json are orphaned — they point at dist-lib/dot-layout-grid but no executor references them.
Acceptance Criteria
libs/dotcms
libs/dot-layout-grid
Both
Priority
Low
Additional Context
Audit of the rest of the rollout
After two dead projects in a row, all 44 rollout projects were swept for the same profile (0 dependents + skip: tags). The problem is bounded — these two are the only dead libraries:
| Project |
Type |
Dependents |
Skips |
Verdict |
dotcms |
library |
0 |
test, lint, build |
Dead — remove |
dot-layout-grid |
library |
0 |
test, lint |
Dead — remove |
dotcms-block-editor |
application |
0 |
test, lint |
Normal — apps have no dependents |
dotcms-scss |
library |
0 |
test, lint |
Already out of scope (SCSS only) |
mcp-server |
application |
0 |
build |
Already out of scope |
Root cause: the 44 sub-issues were generated from the Nx graph without checking whether each project was still alive. Worth verifying that before generating automated rollouts in future.
Reproduce
cd core-web
# libs/dotcms — 2 errors remain with every strict flag off (the broken 'dotcms-models' import)
pnpm exec tsc -p libs/dotcms/tsconfig.lib.json --noEmit \
--strict false --noPropertyAccessFromIndexSignature false --noImplicitReturns false
# libs/dot-layout-grid — 2 errors with no strict flags (ComponentFactoryResolver no longer exists)
pnpm exec tsc -p libs/dot-layout-grid/tsconfig.lib.json --noEmit
# neither has dependents
pnpm exec nx graph --file=/tmp/graph.json
# then inspect graph.dependencies for edges targeting "dotcms" or "dot-layout-grid"
Description
Two Nx libraries in
core-webare dead code and should be removed. Both have zero consumers, are excluded from CI, and do not compile today.They surfaced while working through the strict-mode rollout (epic #35932) — enabling
stricton either would mean fixing type errors in code nobody uses, with zero verification signal since no CI target compiles them.libs/dotcmsinitDotCMSSDK (dotcms@0.0.21)@dotcms/clientlibs/dot-layout-gridNgGridlayout grid (vendoredangular2-grid)libs/template-builder1.
libs/dotcms— legacyinitDotCMSSDKNobody imports it — verified five ways
@dotcms/dotcmsimports across the repoinitDotCMSsymbol usagedotcmsdeclared as a dependency in anypackage.jsonlibs/dotcmstsconfig.base.json:35(alias),nx.json:227(Jest plugin glob),README.MD:12Unmaintained and broken
libs/dotcms/project.jsonis tagged["skip:test", "skip:lint", "skip:build"]— CI never builds, lints, or tests it.strictdisabled.src/lib/api/DotApiContentType.ts:1andsrc/lib/api/DotApiForm.ts:1import from'dotcms-models', a path alias that no longer exists (current one is@dotcms/dotcms-models) — 5TS2307errors regardless of strict mode.publishtarget points attools/scripts/publish.mjs, which does not reference it, and no workflow invokes it.2.
libs/dot-layout-grid— legacyNgGridlayout gridNobody imports it — verified four ways
@dotcms/dot-layout-gridalias usagetsconfig.base.json:33NgGridModule,NgGrid,NgGridItem,NgGridConfig,NgGridPlaceholder, …) in.tsnggrid,ng-grid) in.htmlThe symbol and template searches matter here — it is a library of Angular directives, consumed from templates, so the path alias alone would not be sufficient proof.
Dead for two years, and broken
5e75d4ddb0(2024-08-22, "remove unused code from old template builder"), which removeddot-edit-layout-grid,dot-container-selector-layoutanddot-edit-layout.service.tsfromapps/dotcms-ui. Every commit touching it since is a mechanical sweep (Angular v19/v20, Nx 23, eslint 9, theinject()codemod).src/lib/directives/NgGrid.ts:8importsComponentFactoryResolverfrom@angular/core, removed from Angular (deprecated in v13, dropped in v20+) — 2 errors present without enabling strict.package.jsondeclarespeerDependenciesof@angular/common/@angular/coreat^6.0.0 || ^7.2.0; the workspace is on Angular 21+.buildtarget at all —project.jsondefines onlytest, and it is tagged["skip:test", "skip:lint"]. Nothing compiles it, not even an inferred target.dot-layout-griddoes not exist in the registry (version: 0.0.1). No external consumers are possible.ng-package.jsonandng-package.prod.jsonare orphaned — they point atdist-lib/dot-layout-gridbut no executor references them.Acceptance Criteria
libs/dotcmsdotcms@0.0.21on npm.core-web/libs/dotcms/.@dotcms/dotcmspath alias fromcore-web/tsconfig.base.json.libs/dotcms/**/*entry from the@nx/jest/pluginincludeglob incore-web/nx.json.core-web/README.MD(line 12).npm deprecate dotcms "This package is no longer maintained. Use @dotcms/client instead."so external users get a migration pointer.libs/dot-layout-gridcore-web/libs/dot-layout-grid/(including the orphanedng-package.json/ng-package.prod.json).@dotcms/dot-layout-gridpath alias fromcore-web/tsconfig.base.json(line 33).core-web/README.MD(line 13).Both
pnpm exec nx affected -t build,lint,test --base=origin/mainstays green.pnpm exec nx show projectsno longer listsdotcmsordot-layout-grid.Priority
Low
Additional Context
dotcmsdot-layout-gridcore-webAudit of the rest of the rollout
After two dead projects in a row, all 44 rollout projects were swept for the same profile (0 dependents +
skip:tags). The problem is bounded — these two are the only dead libraries:dotcmsdot-layout-griddotcms-block-editordotcms-scssmcp-serverRoot cause: the 44 sub-issues were generated from the Nx graph without checking whether each project was still alive. Worth verifying that before generating automated rollouts in future.
Reproduce