Skip to content

Commit 294d642

Browse files
author
Tomasz John
committed
- link to navlink
- link.sh update
1 parent f107c35 commit 294d642

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

link.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
npm link ../coreui-pro-react-admin-template/node_modules/react
2-
npm link ../coreui-pro-react-admin-template/node_modules/react-dom
3-
npm link ../coreui-pro-react-admin-template/node_modules/react-router-dom
1+
npm link ../pro/node_modules/react
2+
npm link ../pro/node_modules/react-dom
3+
npm link ../pro/node_modules/react-router-dom

src/CLink.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import React from 'react';
22
import PropTypes from 'prop-types';
33
import classNames from 'classnames';
44
import {tagPropType, mapToCssModules} from './Shared/helper.js';
5-
import {Link} from 'react-router-dom';
5+
import {NavLink} from 'react-router-dom';
66

77
//component - CoreUI / CLink
88

@@ -49,7 +49,7 @@ const CLink = props=>{
4949

5050
return (
5151
to ?
52-
<Link to={to} {...attributes} className={classes} ref={innerRef} /> :
52+
<NavLink to={to} {...attributes} className={classes} ref={innerRef} /> :
5353
<a href={href2} {...attributes} className={classes} onClick={onClick} ref={innerRef} />
5454
);
5555

0 commit comments

Comments
 (0)