The optional getCss loader option is serialized into the generated module, so it must be a self-contained function without closed-over variables.