Skip to content

Commit 25dab59

Browse files
committed
maint: Document patternslib global variables.
1 parent 6fee709 commit 25dab59

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,18 @@ To facilitate debugging you can change the default log level through the URL que
134134
- `http://www.example.com/?loglevel-inject=DEBUG` changes the log level for just the inject pattern to `DEBUG`.
135135
- `http://www.example.com/?loglevel=ERROR&loglevel-inject=INFO` changes the standard log level error, but enables messages at the `INFO` level for the inject pattern.
136136

137+
### Patternslib global variables
138+
139+
There are some global variables that are available and can be used to make
140+
global settings or access otherwise hidden objects.
141+
142+
| Global variable | Purpose | Default |
143+
| --------------- | ------- | ------ |
144+
| window.__patternslib_import_styles | Whether to import pattern-specific styles | false |
145+
| window.__patternslib_registry | Global access to the Patternslib registry object. | - |
146+
| window.__patternslib_registry_initialized | True, if the registry has been initialized. | false |
147+
| window.__patternslib_disable_modernizr (Deprecated) | Disable modernizr, but still write the js/no-js classes to the body. | undefined |
148+
137149

138150
### Bundle build analyzation
139151

0 commit comments

Comments
 (0)