External module "visua"

Index
Interfaces
Functions
Functions
Const

visua

  • Builds a StyleMap from the provided identity stylesheets.

    If called without options, the visua method searches for a file named exactly identity.css in the current working directory:

    const styleMap = visua();
    

    The path option can be used to specify a relative path to a directory containing the file identity.css or to a specific file.

    The following example searches for a file named identity.css in cwd/subdir:

    const styleMap = visua({
        path: 'subdir',
    });
    

    The following example loads a file named main.css in subdir subdirectory:

    const styleMap = visua({
        path: 'subdir/main.css',
    });
    

    The strict option can be used to terminate the process on parse errors, otherwise Visua will try to recover from soft errors in the css:

    const styleMap = visua({
        path: 'subdir/main.css',
        strict: true,
    });
    
    Parameters Returns StyleMap

    The generated StyleMap