docs
evals
scenario-1
scenario-10
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
{
"context": "This criteria evaluates how well the engineer uses postcss-modules-extract-imports to handle CSS Modules composes declarations, particularly focusing on topological sorting and cycle detection capabilities. The evaluation assesses proper plugin integration, configuration of the failOnWrongOrder option, and correct handling of import order validation.",
"type": "weighted_checklist",
"checklist": [
{
"name": "PostCSS integration",
"description": "Uses postcss.parse() to parse CSS content and creates a PostCSS processor instance with postcss-modules-extract-imports plugin properly registered.",
"max_score": 15
},
{
"name": "Plugin initialization",
"description": "Imports and initializes the postcss-modules-extract-imports plugin using require('postcss-modules-extract-imports') and invokes it as a function to create the plugin instance.",
"max_score": 15
},
{
"name": "failOnWrongOrder configuration",
"description": "Configures the plugin with the failOnWrongOrder option set based on the options parameter passed to the validateCssModuleImports function, enabling strict import order validation when required.",
"max_score": 20
},
{
"name": "CSS processing",
"description": "Uses the PostCSS processor's process() method to apply the extract-imports plugin to the parsed CSS, properly handling the async nature of PostCSS processing.",
"max_score": 15
},
{
"name": "Error handling",
"description": "Properly catches and handles errors thrown by the plugin when nondeterministic import order or circular dependencies are detected, allowing errors to propagate to the caller as specified in the API.",
"max_score": 15
},
{
"name": "Result extraction",
"description": "Extracts the transformed CSS string from the PostCSS processing result using result.css or result.toString() and returns it as specified in the API.",
"max_score": 10
},
{
"name": "Async implementation",
"description": "Implements the function as async and properly awaits the PostCSS processing promise, matching the API signature that returns Promise<string>.",
"max_score": 10
}
]
}