简体   繁体   中英

Code breaks syntax highlighting in Atom / Nuclide

This Javascript / React Native code, which works just fine, breaks the syntax highlighting in Atom / Nuclide for anything that comes after it. Is there anything wrong with the code or is it the syntax highlighting engine?

static navigationOptions = {
    headerTitle: "TFN Top Headlines",
    headerTitleStyle: { fontFamily: "Iowan Old Style" },
    headerLeft: (
      <Icon
        size={35}
        onPress={() => {
          _this.toggleMenu();
        }}
        style={{
          marginLeft: 10
        }}
        name="navicon"
      />
    )
  };

在此处输入图片说明

You will need to install a Plug-in to support JSX formatting.

You could try https://atom.io/packages/language-babel

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM