Get text from android android.intent.action.PROCESS_TEXT
intent-filter
npm install react-native-process-text-intent
import { getProcessTextIntent } from 'react-native-process-text-intent';
// ...
getProcessTextIntent()
.then((textResult) => {
if (textResult) {
console.log(textResult, 'ProcessedText'); // here will be your processed Text coming from android.intent.action.PROCESS_TEXT intent-filter
}
})
.catch((error) => {
console.log(error);
});
};
first you need to add this intent-filter
in AndroidManifest.xml
<intent-filter>
<action android:name="android.intent.action.PROCESS_TEXT" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="text/plain" />
</intent-filter>
See the contributing guide to learn how to contribute to the repository and the development workflow.
MIT
Made with create-react-native-library