New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

react-native-simple-twitter

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-simple-twitter - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

example/.babelrc

4

package.json
{
"name": "react-native-simple-twitter",
"version": "1.0.0",
"version": "1.0.1",
"description": "Twitter API client for React Native",

@@ -27,2 +27,2 @@ "main": "index.js",

}
}
}

@@ -31,2 +31,3 @@ # React-Native-Simple-Twitter

Text,
Alert,
StyleSheet

@@ -38,8 +39,8 @@ } from 'react-native'

/* other */
import twitter, { TWLoginButton } from '../../util/twitter'
/* import twitter */
import twitter, { TWLoginButton } from 'react-native-simple-twitter'
@connect(
state => ({
user:state.user
user: state.user
})

@@ -66,3 +67,3 @@ )

componentWillMount() {
async componentWillMount() {
if (this.props.user.token) {

@@ -93,2 +94,20 @@ twitter.setAccessToken(this.props.user.token, this.props.user.token_secret)

this.props.dispatch({ type: "USER_SET", user: user })
Alert.alert(
"Success",
"ログインできました",
[
{
text: 'Go HomeScreen',
onPress: () => {
this.props.dispatch(NavigationActions.reset({
index: 0,
actions: [
NavigationActions.navigate({ routeName: 'Home' })
]
}))
}
}
]
)
}

@@ -163,3 +182,3 @@

```
Checkout [example](#usage).
Checkout [example](https://github.com/watanabeyu/react-native-simple-twitter/tree/v1.0.x/example).

@@ -166,0 +185,0 @@ ## TWLoginButton props

@@ -5,2 +5,4 @@ /* lib */

export default Request = async (_method = "GET", _url = "", _params = {}) => {
url = _url.replace(/\!/g, "%21").replace(/\'/g, "%27").replace(/\(/g, "%28").replace(/\)/g, "%29").replace(/\*/g, "%2A");
const options = {

@@ -13,3 +15,3 @@ method: _method,

return await fetch(_url, options)
return await fetch(url, options)
.then(response => {

@@ -16,0 +18,0 @@ const contentType = response.headers.get("content-type")

@@ -65,3 +65,3 @@ /* npm */

export const createSignature = (_params, _method, _url, _consumerSecret, _tokenSecret = null) => {
const encodedParameters = encodeParamsToString(_params);
const encodedParameters = encodeParamsToString(_params).replace(/\!/g, '%21').replace(/\'/g, '%27').replace(/\(/g, '%28').replace(/\)/g, '%29').replace(/\*/g, '%2A');
const encodedRequestURL = encodeURIComponent(_url);

@@ -68,0 +68,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc