mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-09 11:13:57 +08:00
add preprocessors to plugins
This commit is contained in:
Vendored
+18
@@ -30,12 +30,30 @@ declare module Less {
|
||||
|
||||
class PluginManager {
|
||||
constructor(less: LessStatic);
|
||||
|
||||
addPreProcessor(preProcessor: PreProcessor, priority?: number): void;
|
||||
}
|
||||
|
||||
interface Plugin {
|
||||
install: (less: LessStatic, pluginManager: PluginManager) => void;
|
||||
}
|
||||
|
||||
interface PreProcessor {
|
||||
process: (src: string, extra: PreProcessorExtraInfo) => string;
|
||||
}
|
||||
|
||||
interface PreProcessorExtraInfo {
|
||||
context: {
|
||||
pluginManager: PluginManager;
|
||||
};
|
||||
|
||||
fileInfo: RootFileInfo;
|
||||
|
||||
imports: {
|
||||
[key: string]: any;
|
||||
};
|
||||
}
|
||||
|
||||
interface SourceMapOption {
|
||||
sourceMapURL: string;
|
||||
sourceMapBasepath: string;
|
||||
|
||||
Reference in New Issue
Block a user