0.0.4 • Published 3 years ago

@tkc-fe/react-native-navigation-crawler v0.0.4

Weekly downloads
-
License
-
Repository
github
Last release
3 years ago

Introduction

This package will crawl react native packages looking for screens - it will then optionally output a simple HTML site that will allow you to see the different screens relations and open files directly.

Usage

npx @tkc-fe/react-native-navigation-crawler <route-input> <html-output>

Usage Example

npx @tkc-fe/react-native-navigation-crawler ./src/stacks/Drawer.tsx ./crawl-output

Installation

yarn add @tkc-fe/react-native-navigation-crawler or npm i @tkc-fe/react-native-navigation-crawler

Example 📕


import ReactRouteCrawler from '@tkc-fe/react-native-navigation-crawler'

const crawler = new ReactRouteCrawler()
const screens = crawler.getComponentScreens(
    './src/stacks/RootStack.tsx',   // The route to map screens within.
    true                            // If we should do this recursively.
)                           

Config ⚙️


// You can also pass different optional paraments for the crawlers setup.
const crawler = new ReactRouteCrawler({
    configPath:         './tsconfig.json',      // The location of the tsconfig -- Default: ./tsconfig.json
    sourceFilesGlob:    './src/**/*.tsx'        // The glob pattern for files   -- Default: ./src/**/*.tsx
})
0.0.4

3 years ago

0.0.35

3 years ago

0.0.34

3 years ago

0.0.33

3 years ago

0.0.32

3 years ago

0.0.31

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago