Coder Social home page Coder Social logo

prisma-archive / react-native-fullstack-graphql Goto Github PK

View Code? Open in Web Editor NEW
208.0 20.0 32.0 3.21 MB

๐Ÿš€ Starter projects for mobile applications based on React Native & GraphQL.

JavaScript 100.00%
apollo instagram react-native graphql graphcool

react-native-fullstack-graphql's People

Contributors

bestan avatar bramski avatar devanb avatar marktani avatar nikolasburk avatar renovate-bot avatar renovate[bot] avatar schickling avatar timsuchanek avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

react-native-fullstack-graphql's Issues

on iOS imageUrl should be https and not http to display images

As found by Nilian, http://stackoverflow.com/questions/38153335/react-native-loading-image-over-https-works-while-http-does-not-work .
Server side should verify thant imageUrl is https, otherwise on RN side, a rewrite rule can be implemented in Post.js

render () {
    return (
      <View style={{flex: 1, width: 150, height: 150}}>
        <Image
          source={{ uri: this.props.post.imageUrl.replace(/^http:\/\//i, 'https://') }}
          style={{flex: 1, width: 150, height: 150}}
        />
        <Text>{this.props.post.description}</Text>
      </View>
    )
  }

[authentication-with-auth0-and-apollo] Cannot read property 'init' of undefined

Receiving following error from the authentication-with-auth0-and-apollo example:

Versions:

Steps to reproduce:

Expected behavior:

  • App should switch to a login page view.

Solution:

  1. Add the following import to .../android/app/src/main/java/com/auth0example/MainApplication.java:
    import com.auth0.lock.react.LockReactPackage;

  2. In the same MainApplication.java file, add the LockReactPackage() module as shown below:

    /**
     * A list of packages used by the app. If the app uses additional views
     * or modules besides the default ones, add more packages here.
     */
    @Override
    protected List<ReactPackage> getPackages() {
        return Arrays.<ReactPackage>asList(
            new MainReactPackage(),
            //Other RN modules
            new LockReactPackage()
        );
    }
  1. In the .../android/app/src/main/AndroidManifest.xml add the following inside <application> tag:
<!--Auth0 Lock-->
<activity
  android:name="com.auth0.lock.LockActivity"
  android:theme="@style/Lock.Theme"
  android:screenOrientation="portrait"
  android:launchMode="singleTask">
</activity>
<!--Auth0 Lock End-->
<!--Auth0 Lock Embedded WebView-->
<activity
    android:name="com.auth0.identity.web.WebViewActivity"
    android:theme="@style/Lock.Theme">
</activity>
<!--Auth0 Lock Embedded WebView End-->
<!--Auth0 Lock Passwordless-->
<activity
    android:name="com.auth0.lock.passwordless.LockPasswordlessActivity"
    android:theme="@style/Lock.Theme"
    android:screenOrientation="portrait"
    android:launchMode="singleTask">
</activity>
<activity
    android:name="com.auth0.lock.passwordless.CountryCodeActivity"
    android:theme="@style/Lock.Theme">
</activity>
<!--Auth0 Lock Passwordless End-->

Note:

  • This issue is likely occurring on all of Graphcool's Auth0 based react-native examples.
  • See Auth0's manual configuration instructions for details on correcting this and other errors you will incur with graphcool's react-native auth0 examples.

[react-native-graphql] Execution failed for task ':app:transformResourcesWithMergeJavaResForDebug'

Receiving following error from the authentication-with-auth0-and-apollo example:

Versions:

Steps to reproduce:

Expected behavior:

  • App should build and run on android

Solution:

  • Error is resolved by adding the following to the android{ ... } section in the .../android/app/build.gradle file:

packagingOptions {exclude 'META-INF/LICENSE' exclude 'META-INF/NOTICE'}

Note:

  • This issue is likely occurring on all (seven) of Graphcool's react-native examples
  • See Auth0's manual configuration instructions for details on correcting this and other errors you will incur with graphcool's react-native auth0 examples.

Dependency warnings + xcodebuild errors

Hi! Thanks for this project!

There are some warnings after "yarn install" in authentication-with-auth0-and-apollo project:

warning "[email protected]" has incorrect peer dependency "[email protected] || 15.* || ^15.0.0".
warning "[email protected]" has incorrect peer dependency "react@^0.14.0 || ^15.0.0-0".
warning "[email protected]" has incorrect peer dependency "react@^15.5.4".
warning "[email protected]" has incorrect peer dependency "react@^0.13.0 || ^0.14.0 || ^15.0.0".

Also when I was trying to do "react-native run-ios" I got this error:

Found Xcode workspace ReactNativeApolloAuth0Example.xcworkspace
Launching iPhone 6 (iOS 10.3)...
Building using "xcodebuild -workspace ReactNativeApolloAuth0Example.xcworkspace -configuration Debug -scheme ReactNativeApolloAuth0Example -destination id=BDE6F8BB-F5F4-4ECE-A539-3DDF5AAD8B2E -derivedDataPath build"
User defaults from command line:
    IDEDerivedDataPathOverride = /Users/stan/react-native-graphql/react-native-graphql/authentication-with-auth0-and-apollo/ios/build

xcodebuild: error: The workspace named "ReactNativeApolloAuth0Example" does not contain a scheme named "ReactNativeApolloAuth0Example". The "-list" option can be used to find the names of the schemes in the workspace.

Installing build/Build/Products/Debug-iphonesimulator/ReactNativeApolloAuth0Example.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=2):
Failed to install the requested application
An application bundle was not found at the provided path.
Provide a valid path to the desired application bundle.
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/ReactNativeApolloAuth0Example.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist

So I unable to start this project :(

error while loading : Tunnel exp://url...

Hello,

I try to use this cool auth example, but after clicking on login with google, the loader id displayed and never stop.
if i clic on done (top screen) to hide the browser, i can see an error and the link go back to expo home

i have this error :
no experience found at exp://url....exp.direct/+/redirect
detail : error while loading : Tunnel exp://url....exp.direct/+/redirect#access_token=my_token, code 404

i run the code in ios simulator iphone 7
with xde on mac

thx for your time and your help

[authentication-with-auth0-and-apollo] Deprecated react-native-lock Prevents Running Authentication with Auth0 and Apollo

The npm package react-native-lock has been deprecated in favor of react-native-auth0. In practice, this is a breaking change, as the old API cannot be used with newly created clients. This means that new users working through the examples are unable to get the "Authentication with Auth0 and Apollo" example to function.

Request replacement of react-native-lock with react-native-auth0 following guidelines from the Auth0 React-Native repo.

Dependency deprecation warning: apollo-client-preset (npm)

On registry https://registry.npmjs.org/, the "latest" version (v1.0.8) of dependency apollo-client-preset has the following deprecation notice:

for the best quick start with Apollo Client, please use apollo-boost instead

Marking the latest version of an npm package as deprecated results in the entire package being considered deprecated, so contact the package author you think this is a mistake.

Please take the actions necessary to rename or substitute this deprecated package and commit to your base branch. If you wish to ignore this deprecation warning and continue using apollo-client-preset as-is, please add it to your ignoreDeps array in Renovate config before closing this issue, otherwise another issue will be recreated the next time Renovate runs.

Integrate React Navigation

Thank you so much for the react-native-graphql example! :)
It clarifies a lot for me.

But I'm still struggling with the integration of react-community/react-navigation...
For more complex apps theres no way around a stack navigator and the React Navigation is the de facto standard.

Maybe you could add it to this example or create another that uses it?

checkUri causes issue

The checkUri(client.networkInterface) call in root.js gives the following error:

simulator screen shot 24 mar 2017 12 07 51

Commenting it out makes the app start properly.

Conditionally set HttpLink URI

There is an issue with fetch in React Native that prevents the usage of localhost.

A proposed solution is to use Platform.select to set the ApolloClient's HttpLink uri to one of several options:

const SERVER_URL = __DEV__
  ? Platform.select({
      ios: 'GET_USERS_IP_ADDRESS_AND_APPEND_PORT_4000',
      android: 'http://10.0.2.2:4000'
    })
  : 'USE_PRODUCTION_GRAPHQL_SERVER_ENV_VAR';

Android apparently allows 10.0.2.2 to equal localhost, but I haven't confirmed this myself.

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.