@truffle/compile-solidity
Version:
Compiler helper and artifact manager for Solidity files
14 lines (13 loc) • 739 B
TypeScript
import type Config from "@truffle/config";
/**
* Loads solc and wrap it to parse imports rather than performing a full
* compilation. Returns the wrapped form.
*
* This function optionally accepts an `parser` param, whose only possible
* value is `"solcjs"`. Passing this option indicates that the imports-parser
* should use a wrapped soljson module instead of whatever normal compiler
* the user would use. NOTE that as a result, this function may download solc
* up to twice: first time as usual, to get the specific version, then a second
* time to get the solcjs of that version.
*/
export declare function loadParser({ events, compilers: { solc: solcConfig } }: Config, providedSolc?: any): Promise<(body: string) => any>;