Posts

Showing posts with the label facebook

implementing react-native-fbsdkshare

I have followed the guide written on https://github.com/facebook/react-native-fbsdk to install and use the react-native-fbsdk module. However, when I click the "Share" button it throws the following error: 'Error: undefined is not an object (evaluating \'FBSDKShareDialogInterface.show\') Also 3 warnings appear when I run the app: 'Warning: Native component for "RCTFBSDKShareButton" does not exist' 'Warning: Native component for "RCTFBSDKSendButton" does not exist' 'Warning: Native component for "RCTFBSDKLikeControl" does not exist' This is the code that I use: var FBSDKShare = require('react-native-fbsdkshare'); var { FBSDKShareDialog, FBSDKShareDialogInterface, FBSDKShareLinkContent, FBSDKShareShareButton } = FBSDKShare; shareOnFacebook() { var linkContent = new FBSDKShareLinkContent('https://facebook.com', 'Wow, check out this great site!', ...

How to run React-Native Examples?

I can't find any instructions on how to install and run one of the other Examples provided in 'https://github.com/facebook/react-native/tree/master/Examples' such as 'https://github.com/facebook/react-native/tree/master/Examples/Movies'. The tutorial only tells you to do react-native init AwesomeProject which grabs 'https://github.com/facebook/react-native/tree/master/Examples/SampleApp'. If I clone the entire 'react-native' repository, and then run npm install npm start From the root folder (i.e. '/react-native'), and then open '/react-native/Examples/Movies/Movies.xcodeproj' in Xcode, and Run the project, it seems to build fine. The Simulator comes up, shows a "Movies" intro screen for the app, but then the red screen of death appears with a print out of: :0 and Terminal, where 'npm start' is running at the root folder, prints out: Error: EISDIR, read at Error (native) [02:35:02] <STA...

issue with react-native: start script 'react-native-scripts start'

I'm using node v6.11.3, npm version 3.10.10 and create-react-native-app version: 1.0.0, macOS Sierra 10.12.6 When I tried to follow the instructions I found here: https://facebook.github.io/react-native/docs/getting-started.html#content to create a minimal react-native app, I received the following error 0 info it worked if it ends with ok 1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'start' ] 2 info using npm@3.10.10 3 info using node@v6.11.3 4 verbose run-script [ 'prestart', 'start', 'poststart' ] 5 info lifecycle AwesomeProject@0.1.0~prestart: AwesomeProject@0.1.0 6 silly lifecycle AwesomeProject@0.1.0~prestart: no script for prestart, continuing 7 info lifecycle AwesomeProject@0.1.0~start: AwesomeProject@0.1.0 8 verbose lifecycle AwesomeProject@0.1.0~start: unsafe-perm in lifecycle true 9 verbose lifecycle AwesomeProject@0.1.0~start: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/Users/alejandro.cab...

React-Native: Application has not been registered error

I am currently going through the React-Native tutorials. I began with the Getting Started tutorial, where I made a new react native project and successfully managed to run the project on my device. I then started the Props tutorial, I copied the code snippet and tried to run the project again and had the following error message show up on my screen: I guess it is an error caused by not matching name of project and your registered component. You have inited project with one name, i.e. react-native init AwesomeApp But in your index.ios.js file you register other component AppRegistry.registerComponent('Bananas', () => Bananas); When it must be AppRegistry.registerComponent('AwesomeApp', () => Bananas); Try to fix it. Most of the times the problem is that you have another react-native start (i.e. React Native Packager) server running either on another terminal or another tab of TMUX (if you are using TMUX). You need to find t...

Google, Facebook Sign in support with Flutter

I am new to Flutter, Is there any way that i can provide Sign in using GOOGLE/FACEBOOK with Flutter. Thanks Adding this late answer since now there is a package, flutter_facebook_login that replaces flutter_facebook_connect. Here is a functioning main.dart example that should work. Just keep in mind you must have followed all configuration as described in the repository and must have a facebook app configured: import 'package:flutter/material.dart'; import 'package:flutter_facebook_login/flutter_facebook_login.dart'; import 'dart:async'; void main() => runApp(new MyApp()); class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { return new MaterialApp( title: 'Flutter Facebook Login', theme: new ThemeData( primarySwatch: Colors.blue, ), home: new MyHomePage(title: 'Flutter Login Facebook'), ); } } class MyHomePage extends StatefulWidget { MyHomePage({Key key, this...

Not able to update FBSDKCoreKit POD iOS

I am getting the following error when I try to do pod update. once it failed, I am not even able to do pod install anymore. Installing FBSDKCoreKit (4.36.0) [!] Error installing FBSDKCoreKit [!] /usr/bin/git clone https://github.com/facebook/facebook-ios-sdk.git /var/folders/tq/jky5s5j1589c5nqhs3n7j3d00000gn/T/d20180831-29436-tmqja3 --template= --single-branch --depth 1 --branch sdk-version-4.36.0 Cloning into '/var/folders/tq/jky5s5j1589c5nqhs3n7j3d00000gn/T/d20180831-29436-tmqja3'... warning: Could not find remote branch sdk-version-4.36.0 to clone. fatal: Remote branch sdk-version-4.36.0 not found in upstream origin According to the change log, version 4.36.0 was released yesterday (30th August). It looks like they've forgotten to create a release tag for it yet in their Github repository hosting the Facebook iOS SDK. In the meantime, you can set your pod to: pod 'FBSDKCoreKit', '4.35' pod 'FBSDKLoginKit', '4.35'...

App getting stuck with E/com.facebook.internal.AttributionIdentifiers [duplicate]

This question already has an answer here: How to solve app launch - app is stuck on white screen 6 answers App was running fine till 1 hour back. Suddenly it started getting stuck at the opening and shows 1 line error message in logcat 08-31 15:57:54.924 31700-31700/? E/com.facebook.internal.AttributionIdentifiers: getAttributionIdentifiers should not be called from the main thread That's the only log being shown. There were no changes happened on app this one worked for me com.facebook.android:facebook-android-sdk:4.35.0 If it does not help, open android/build.gradle. Add next lines allprojects { repositories { // ... configurations.all { resolutionStrategy { force 'com.facebook.android:facebook-android-sdk:4.34.0' } } } For cordova you can do: $ cordova plugin rm cordova-plugin-facebook4 $ cordova plugin add cordova-plugin-...