Fix code quality violations and enhance ROUTE-EXISTS-01 rule
Implement JQHTML function cache ID system and fix bundle compilation Implement underscore prefix for system tables Fix JS syntax linter to support decorators and grant exception to Task system SPA: Update planning docs and wishlists with remaining features SPA: Document Navigation API abandonment and future enhancements Implement SPA browser integration with History API (Phase 1) Convert contacts view page to SPA action Convert clients pages to SPA actions and document conversion procedure SPA: Merge GET parameters and update documentation Implement SPA route URL generation in JavaScript and PHP Implement SPA bootstrap controller architecture Add SPA routing manual page (rsx:man spa) Add SPA routing documentation to CLAUDE.md Phase 4 Complete: Client-side SPA routing implementation Update get_routes() consumers for unified route structure Complete SPA Phase 3: PHP-side route type detection and is_spa flag Restore unified routes structure and Manifest_Query class Refactor route indexing and add SPA infrastructure Phase 3 Complete: SPA route registration in manifest Implement SPA Phase 2: Extract router code and test decorators Rename Jqhtml_Component to Component and complete SPA foundation setup 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
202
node_modules/webpack/lib/javascript/JavascriptGenerator.js
generated
vendored
Executable file → Normal file
202
node_modules/webpack/lib/javascript/JavascriptGenerator.js
generated
vendored
Executable file → Normal file
@@ -101,107 +101,6 @@ class JavascriptGenerator extends Generator {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {NormalModule} module module for which the code should be generated
|
||||
* @param {GenerateContext} generateContext context for generate
|
||||
* @returns {Source | null} generated code
|
||||
*/
|
||||
generate(module, generateContext) {
|
||||
const originalSource = module.originalSource();
|
||||
if (!originalSource) {
|
||||
return DEFAULT_SOURCE.source();
|
||||
}
|
||||
|
||||
const source = new ReplaceSource(originalSource);
|
||||
/** @type {InitFragment<GenerateContext>[]} */
|
||||
const initFragments = [];
|
||||
|
||||
this.sourceModule(module, initFragments, source, generateContext);
|
||||
|
||||
return InitFragment.addToSource(source, initFragments, generateContext);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Error} error the error
|
||||
* @param {NormalModule} module module for which the code should be generated
|
||||
* @param {GenerateContext} generateContext context for generate
|
||||
* @returns {Source | null} generated code
|
||||
*/
|
||||
generateError(error, module, generateContext) {
|
||||
return new RawSource(`throw new Error(${JSON.stringify(error.message)});`);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Module} module the module to generate
|
||||
* @param {InitFragment<GenerateContext>[]} initFragments mutable list of init fragments
|
||||
* @param {ReplaceSource} source the current replace source which can be modified
|
||||
* @param {GenerateContext} generateContext the generateContext
|
||||
* @returns {void}
|
||||
*/
|
||||
sourceModule(module, initFragments, source, generateContext) {
|
||||
for (const dependency of module.dependencies) {
|
||||
this.sourceDependency(
|
||||
module,
|
||||
dependency,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
|
||||
if (module.presentationalDependencies !== undefined) {
|
||||
for (const dependency of module.presentationalDependencies) {
|
||||
this.sourceDependency(
|
||||
module,
|
||||
dependency,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
for (const childBlock of module.blocks) {
|
||||
this.sourceBlock(
|
||||
module,
|
||||
childBlock,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Module} module the module to generate
|
||||
* @param {DependenciesBlock} block the dependencies block which will be processed
|
||||
* @param {InitFragment<GenerateContext>[]} initFragments mutable list of init fragments
|
||||
* @param {ReplaceSource} source the current replace source which can be modified
|
||||
* @param {GenerateContext} generateContext the generateContext
|
||||
* @returns {void}
|
||||
*/
|
||||
sourceBlock(module, block, initFragments, source, generateContext) {
|
||||
for (const dependency of block.dependencies) {
|
||||
this.sourceDependency(
|
||||
module,
|
||||
dependency,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
|
||||
for (const childBlock of block.blocks) {
|
||||
this.sourceBlock(
|
||||
module,
|
||||
childBlock,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Module} module the current module
|
||||
* @param {Dependency} dependency the dependency to generate
|
||||
@@ -271,6 +170,107 @@ class JavascriptGenerator extends Generator {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Module} module the module to generate
|
||||
* @param {DependenciesBlock} block the dependencies block which will be processed
|
||||
* @param {InitFragment<GenerateContext>[]} initFragments mutable list of init fragments
|
||||
* @param {ReplaceSource} source the current replace source which can be modified
|
||||
* @param {GenerateContext} generateContext the generateContext
|
||||
* @returns {void}
|
||||
*/
|
||||
sourceBlock(module, block, initFragments, source, generateContext) {
|
||||
for (const dependency of block.dependencies) {
|
||||
this.sourceDependency(
|
||||
module,
|
||||
dependency,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
|
||||
for (const childBlock of block.blocks) {
|
||||
this.sourceBlock(
|
||||
module,
|
||||
childBlock,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Module} module the module to generate
|
||||
* @param {InitFragment<GenerateContext>[]} initFragments mutable list of init fragments
|
||||
* @param {ReplaceSource} source the current replace source which can be modified
|
||||
* @param {GenerateContext} generateContext the generateContext
|
||||
* @returns {void}
|
||||
*/
|
||||
sourceModule(module, initFragments, source, generateContext) {
|
||||
for (const dependency of module.dependencies) {
|
||||
this.sourceDependency(
|
||||
module,
|
||||
dependency,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
|
||||
if (module.presentationalDependencies !== undefined) {
|
||||
for (const dependency of module.presentationalDependencies) {
|
||||
this.sourceDependency(
|
||||
module,
|
||||
dependency,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
for (const childBlock of module.blocks) {
|
||||
this.sourceBlock(
|
||||
module,
|
||||
childBlock,
|
||||
initFragments,
|
||||
source,
|
||||
generateContext
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {NormalModule} module module for which the code should be generated
|
||||
* @param {GenerateContext} generateContext context for generate
|
||||
* @returns {Source | null} generated code
|
||||
*/
|
||||
generate(module, generateContext) {
|
||||
const originalSource = module.originalSource();
|
||||
if (!originalSource) {
|
||||
return DEFAULT_SOURCE.source();
|
||||
}
|
||||
|
||||
const source = new ReplaceSource(originalSource);
|
||||
/** @type {InitFragment<GenerateContext>[]} */
|
||||
const initFragments = [];
|
||||
|
||||
this.sourceModule(module, initFragments, source, generateContext);
|
||||
|
||||
return InitFragment.addToSource(source, initFragments, generateContext);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Error} error the error
|
||||
* @param {NormalModule} module module for which the code should be generated
|
||||
* @param {GenerateContext} generateContext context for generate
|
||||
* @returns {Source | null} generated code
|
||||
*/
|
||||
generateError(error, module, generateContext) {
|
||||
return new RawSource(`throw new Error(${JSON.stringify(error.message)});`);
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = JavascriptGenerator;
|
||||
|
||||
Reference in New Issue
Block a user