resolve: {
extensions: ['.js', 'ts', 'tsx', '.vue', '.json'],
alias: {
'vue$': 'vue/dist/vue.esm.js',
'@': resolve('src'),
}
},
module: {
rules: [
...(config.dev.useEslint ? [createLintingRule()] : []),
{
test: /\.(ts?x)(\?.*)?$/,
loader: 'ts-loader',
} .....
resolve: {
extensions: ['.js', 'ts', 'tsx', '.vue', '.json'],
alias: {
'vue$': 'vue/dist/vue.esm.js',
'@': resolve('src'),
}
},
module: {
rules: [
...(config.dev.useEslint ? [createLintingRule()] : []),
{
test: /\.(ts?x)(\?.*)?$/,
loader: 'ts-loader',
} .....
❯ yarn test:unit
yarn run v1.22.10
$ vue-cli-service test:unit
/bin/sh: vue-cli-service: команда не найдена
error Command failed with exit code 127.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
useEffect(() => {
apiGetOperationsLoan()
.then((response) => {
setOperationsLoan(response.data);
});
apiGetOperationsFinance()
.then((response) => {
setOperationsFinance(response.data);
});
apiGetOperationsServices()
.then((response) => {
setOperationsServices(response.data);
});
apiGetOperationsSystem()
.then((response) => {
setOperationsSystem(response.data);
});
}, []);
<TabBar>
<TabBarItem label="Операции">
<div className="loans-history">
{
operationsLoan.map((loan, index) => {
return <Loan loan={loan} key={index}/>;
})
}
</div>
</TabBarItem>
<TabBarItem label="Финансовые">
<div className="finance-history">
{
operationsFinance.map((finance, index) => {
return <Finance finance={finance} key={index}/>;
})
}
</div>
</TabBarItem>
<TabBarItem label="Системные сообщения">
</TabBarItem>
<TabBarItem label=" рейтинг">
<div className="finance-history">
{
operationsServices.map((finance, index) => {
return <Finance finance={finance} key={index}/>;
})
}
</div>
</TabBarItem>
</TabBar>
{React.Children.map(children, child => React.cloneElement(child, { activeTab }))}