我将API连接到默认权限。
Git:https://github.com/docusign/eg-02-react-implicit-grant
当我第一次解密从Git下载的文件时,aux有一个小错误,所以我通过将其重命名为auxs并修复所有链接问题来修改它。但后来遇到这个问题,我想解决它。谢谢。
TypeError: Object expected
./src/index.js
C:/Users/benzaza/test/eg-02-react-implicit-grant-master/src/index.js:26
23 | sendSignEnv: sendSignEnvReducer
24 | });
25 |
> 26 | const store = createStore(rootReducer, composeEnhancers(
27 | applyMiddleware(thunk)
28 | ));
尝试更改为:
const composeEnhancers = process.env.NODE_ENV === 'development'
? (window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ) : compose;
我不使用null
,因为它将被compose
取代(你使用||
)。
我没有看到
预期对象:docusign api)
但我看到一个错误:
composeEnhancers不是一个功能
我看到错误,接下来需要解决的问题。(T-T)
Failed to compile
./src/index.js
Syntax error: C:/Users/benzaza/test/eg-02-react-implicit-grant-master/src/index.js: Unexpected token, expected : (17:110)
15 | import sendSignEnvReducer from './store/reducers/sendSignEnv';
16 |
> 17 | const composeEnhancers = process.env.NODE_ENV === 'development' ? window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ as typeof compose || compose;
|