itinance / itinance/react-native-fs
Passing cookie in header for authentication JSessionid
- Dominant language
- C++
- Stars
- 5k
- Forks
- 1k
- PR merge metrics
- No merged PRs in 30d
Description
Example:
```
console.log("JSESSIONID="+jsessionID);
var options = {
Cookie: 'JSESSIONID='+jsessionID
};
if(path.substring(path.length - 4, path.length).toLowerCase() !== ".pdf" ){
Alert.alert(
"Attention",
"It's not a possible to open document because not is type pdf."
);
this.setState({'error':"Archive incompatible"});
}else {
RNFS.downloadFile({ fromUrl: url, toFile: path, headers: options // headers: headers
}).then(
res => {
console.log('res:'+res);
}).then(content => {
console.log('content:'+content);
}).catch(error => {
console.log('error###:'+error)
});
}
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.