Can not import "TabPane"
Same for me.
I was able to get this to work in my code with version 12.5.6 by coding: import Tabs from 'rc-tabs'; import TabPane from 'rc-tabs/es/TabPanelList/TabPane'; TabPane is not re-exported from the package at the top level. Things must have been different in earlier releases.
That's not helping when it's being used by a dependency rather than by my own code. For example, the npmjs react-widgets package is code that doesn't want to work with the current version. react-widgets hasn't been updated in a year.
import Tabs from 'rc-tabs';
var callback = function(key) {
console.log(key);
};
const z = [
{
key: "1",
label: "Google",
children: (
<div className="text-xl">
<p>Lorem Ipsum is simply dummy text of the printing and typesetting</p>
</div>
),
},
{
key: "2",
label: <p>Amazon</p>,
children:
"Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit...",
disabled: true
},
{
key: "3",
label: <p>Twitter</p>,
children: (
<div>
"There is no one who loves pain itself, who seeks after it and wants to
have it, simply because it is pain..."
</div>
),
},
];
React.render(
<Tabs
tabPosition="bottom"
items={z}
defaultActiveKey="1"
className="md:w-[70%] w-full mx-auto p-2 border-0"
onChange={callback}
style={{color:"yellow"}}
/>
);
I have opened a pr with updated Read-Me file, tabpane is removed from import in newer versions.
Still nothing on this?
Just downgrading it !
Just downgrading it !
already done that, but wanted to use the latest version, as I like to keep the packages I use up to date.