From ae18284e5af128e1fca0b42f284b558dd7dce73d Mon Sep 17 00:00:00 2001 From: Adam Stankiewicz Date: Wed, 4 Sep 2019 17:39:23 +0200 Subject: Disable jsx when ts or js is disabled, closes #414 --- after/ftplugin/javascript.vim | 2 +- after/ftplugin/typescript.vim | 2 +- after/indent/javascript.vim | 2 +- after/indent/typescript.vim | 2 +- after/syntax/javascript.vim | 2 +- after/syntax/jsx_pretty.vim | 2 +- after/syntax/typescript.vim | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) (limited to 'after') diff --git a/after/ftplugin/javascript.vim b/after/ftplugin/javascript.vim index 4a6346d9..463b854a 100644 --- a/after/ftplugin/javascript.vim +++ b/after/ftplugin/javascript.vim @@ -14,7 +14,7 @@ if exists('b:undo_ftplugin') else let b:undo_ftplugin = 'setlocal iskeyword< suffixesadd<' endif -if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1 +if exists('g:polyglot_disabled') && (index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) finish endif diff --git a/after/ftplugin/typescript.vim b/after/ftplugin/typescript.vim index 21da03be..d307f5d4 100644 --- a/after/ftplugin/typescript.vim +++ b/after/ftplugin/typescript.vim @@ -1,4 +1,4 @@ -if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1 +if exists('g:polyglot_disabled') && (index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) finish endif diff --git a/after/indent/javascript.vim b/after/indent/javascript.vim index 275073fa..8c2254d6 100644 --- a/after/indent/javascript.vim +++ b/after/indent/javascript.vim @@ -1,4 +1,4 @@ -if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1 +if exists('g:polyglot_disabled') && (index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) finish endif diff --git a/after/indent/typescript.vim b/after/indent/typescript.vim index 4e281b22..acc283f0 100644 --- a/after/indent/typescript.vim +++ b/after/indent/typescript.vim @@ -1,4 +1,4 @@ -if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1 +if exists('g:polyglot_disabled') && (index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) finish endif diff --git a/after/syntax/javascript.vim b/after/syntax/javascript.vim index 27818b58..1d2064b5 100644 --- a/after/syntax/javascript.vim +++ b/after/syntax/javascript.vim @@ -1,4 +1,4 @@ -if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1 +if exists('g:polyglot_disabled') && (index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) finish endif diff --git a/after/syntax/jsx_pretty.vim b/after/syntax/jsx_pretty.vim index bc98202a..f37a084b 100644 --- a/after/syntax/jsx_pretty.vim +++ b/after/syntax/jsx_pretty.vim @@ -1,4 +1,4 @@ -if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1 +if exists('g:polyglot_disabled') && (index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) finish endif diff --git a/after/syntax/typescript.vim b/after/syntax/typescript.vim index f39d755f..df500404 100644 --- a/after/syntax/typescript.vim +++ b/after/syntax/typescript.vim @@ -1,4 +1,4 @@ -if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1 +if exists('g:polyglot_disabled') && (index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) finish endif -- cgit v1.2.3