0
votes

I follow the guide at https://developer.microsoft.com/en-us/fabric

I try to import like the guide shows:

import  {TextField}  from 'office-ui-fabric-react/lib/TextField';

My project compiles without errors but when I try to run it, it crashes and this gets logged out: Uncaught SyntaxError: Unexpected token export

How come?

1

1 Answers

0
votes

You don't want to include office-ui-fabric-react/lib/TextField';
just import import {TextField} from 'office-ui-fabric-react';

Check this reference link [https://codesandbox.io/embed/y0o9o2815v]