File tree Expand file tree Collapse file tree 2 files changed +17
-10
lines changed
Expand file tree Collapse file tree 2 files changed +17
-10
lines changed Original file line number Diff line number Diff line change @@ -42,6 +42,11 @@ export interface DevtoolsOptions {
4242 clean ?: boolean
4343 }
4444
45+ /**
46+ * Disable Logux Client in the componenet inspector.
47+ */
48+ client ?: boolean
49+
4550 /**
4651 * Disable action messages with specific types.
4752 */
Original file line number Diff line number Diff line change @@ -39,16 +39,18 @@ export const devtools = {
3939 api => {
4040 devtools . api = api
4141
42- api . on . inspectComponent ( payload => {
43- if ( payload . instanceData ) {
44- payload . instanceData . state . push ( {
45- type : 'Logux' ,
46- key : '$client' ,
47- editable : false ,
48- value : client
49- } )
50- }
51- } )
42+ if ( options . client !== false ) {
43+ api . on . inspectComponent ( payload => {
44+ if ( payload . instanceData ) {
45+ payload . instanceData . state . push ( {
46+ type : 'Logux' ,
47+ key : '$client' ,
48+ editable : false ,
49+ value : client
50+ } )
51+ }
52+ } )
53+ }
5254
5355 if ( layers . state !== false ) {
5456 api . addTimelineLayer ( {
You can’t perform that action at this time.
0 commit comments