Giter Site home page Giter Site logo

michealnguyen1 / ribstreeviewerclient Goto Github PK

View Code? Open in Web Editor NEW

This project forked from srea/ribstreeviewerclient

0.0 0.0 0.0 2.05 MB

Real Time viewing attached RIBs Tree on Browser

License: MIT License

Objective-C 0.81% Swift 83.06% JavaScript 0.82% HTML 0.39% Ruby 0.09% C 14.09% Makefile 0.16% Shell 0.57%

ribstreeviewerclient's Introduction

Carthage compatible

RIBsTreeViewer

Real Time viewing attached RIBs Tree on Browser

Demo

Using the Libraries

XCFramework

Add the xcframework to your project。

./Products/RIBsTreeViewerClient.xcframework

CocoaPods

This is not supported because the RIBs do not provide an up-to-date PodSpec, making it difficult to resolve dependencies.

Carthage

github "srea/RIBsTreeViewerClient"
$ carthage update --platform iOS --no-use-binaries

Build Phase


Carthage CopyFrameworks (ONLY DEBUG)

 if [ ${CONFIGURATION%%-*} == "Debug" ]; then
    /usr/local/bin/carthage copy-frameworks
 fi

Basic setup

@UIApplicationMain
public class AppDelegate: UIResponder, UIApplicationDelegate {

    private var ribsTreeViewer: RIBsTreeViewer? = nil
    
    public func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
        let window = UIWindow(frame: UIScreen.main.bounds)
        self.window = window

        let result = RootBuilder(dependency: AppComponent()).build()
        let launchRouter = result.launchRouter
        self.launchRouter = launchRouter
        urlHandler = result.urlHandler
        launchRouter.launch(from: window)
        startRIBsTreeViewer(launchRouter: launchRouter)
        return true
    }
}
// MARK: - RIBsTreeViewer

#if DEBUG
import RIBsTreeViewerClient

extension AppDelegate {
    private func startRIBsTreeViewer(launchRouter: Routing) {
        if #available(iOS 13.0, *) {
            ribsTreeViewer = RIBsTreeViewerImpl.init(router: launchRouter,
                                                     options: [.webSocketURL("ws://0.0.0.0:8080"),
                                                               .monitoringIntervalMillis(1000)])
            ribsTreeViewer?.start()
        } else {
            // RIBsTreeViewer is not supported OS version.
        }
    }
}
#endif

Installing

$ npm install yarn

Starting the websocke server

$ npx yarn install
$ node index.js

Open the page.

$ npx yarn install
$ npx webpack
$ open ./public/index.html

ribstreeviewerclient's People

Contributors

srea avatar imairi avatar kuritatu18 avatar dependabot[bot] avatar

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.