GithubHelp home page GithubHelp logo

martin-dominguez / liferay-react-native-demo Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ethib137/liferay-react-native-demo

0.0 0.0 0.0 3.35 MB

A React Native demo app for Liferay built with Expo.

JavaScript 100.00%

liferay-react-native-demo's Introduction

Liferay React Native Demo App

An example app for Liferay utilizing Liferay's headless apis.

Setup the Code

Please provide feedback for this. If you find anything is missing add an issue to this repo so I can update the steps. Or even better, send a pull request. ;)

This is a JavaScript applicaiton so you will need node and npm installed.

This Liferay React Native App is built using Expo which simplifies the creation of React Native apps.

$ npm install expo-cli --global

$ expo install

$ expo start

Authentication

The App can be configured to use either OAuth2 or Basic Auth.

OAuth2

To set OAuth2 up on Liferay you will need to create a new OAuth application through Liferay's administration. Configure it as shown in the image below.

Configuration

You will then need to enable scopes to give the OAuth application access to Liferay. I've found this to be a little finnicky and thus simply enabled everything. To test any changes you make to scopes, you will need to log out and back in on the app.

Scopes

At this point it should be working.

Permissioned Images

Viewing images that do not include guest permissions may require additional configuration in your Liferay instance. If you are using basic Auth make sure "System Settings > API Authentication > Basic Auth Header" includes your image's base url. For example: /o/adaptive-media/*.

Android Emulator

In order to connect to you local Liferay instance from an Android emulator you will need to Liferay Server URL from the Configurations page to http://10.0.2.2:8080.

Contributing Guidlines

Before sending a pull request please make sure to run the following formatting commands. Fix any errors you see.

$ npx eslint src

$ npm run prettier

Issues & Questions Welcome

liferay-react-native-demo's People

Contributors

dependabot[bot] avatar ethib137 avatar jverweijl avatar martin-dominguez 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.