Giter Club home page Giter Club logo

Comments (4)

PedroBern avatar PedroBern commented on May 12, 2024 1

released in v1.2.0

from react-native-collapsible-tab-view.

PedroBern avatar PedroBern commented on May 12, 2024

Hi @andreialecu, I don't plan to add the integration by myself, because for now it solves my use case. But if you or someone is willing to open a PR, I would accept it :)

Implementation

The implementation is super simple, you can do it in 3 steps:

1. MaterialTopTabsCollapsibleTabView

Same as the original, replacing the TabView here by the CollapsibleTabView.

2. MaterialTopTabsCollapsibleNavigator

Just like in step 1, same as the original, replacing the MaterialTopTabView here by the component of step 1.

3. Changes in the CollapsibleTabView

There is this one caveat, currently, the CollapsibleTabView uses the route.key as identifier, and to make this work with the react-navigation we need to use route.name. So you need to make changes here, and remember to use the name in the hooks:

--- activeRouteKey: routes[index].key,
+++ activeRouteKey: routes[index].name,

Investigation

I'm not using it and it may have bugs, especially for the snap effect. Please if you can fork, experiment and maybe find ways to improve, would be really nice :)

from react-native-collapsible-tab-view.

andreialecu avatar andreialecu commented on May 12, 2024

Thanks for the pointers! I opened a PR at #10 which implements this, and it seems to work perfectly in conjunction with #9

from react-native-collapsible-tab-view.

PedroBern avatar PedroBern commented on May 12, 2024

merged #10 👍

from react-native-collapsible-tab-view.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.