File tree Expand file tree Collapse file tree 4 files changed +18
-2
lines changed
Expand file tree Collapse file tree 4 files changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -77,3 +77,4 @@ example/RNExampleApp/ios/main.jsbundle
7777example /RNExampleApp /ios /main.jsbundle.meta
7878example /RNExampleApp /third-party
7979example /RNExampleApp /yarn.lock
80+ example /RNExampleApp /src /license.js
Original file line number Diff line number Diff line change 1+
2+ const fs = require ( 'fs' ) ;
3+ const path = require ( 'path' ) ;
4+
5+ const filePath = path . join ( __dirname , 'src/license.js' ) ;
6+
7+ if ( ! fs . existsSync ( filePath ) ) {
8+ // If the file doesn't exist, create it with an initial placeholder content
9+ fs . writeFileSync ( filePath , `
10+ const license = '{REPLACE_YOUR_LICENSE_KEY}';
11+
12+ module.exports = { license };
13+ ` ) ;
14+ }
Original file line number Diff line number Diff line change 44 "private" : true ,
55 "scripts" : {
66 "initProject" : " yarn add expo && yarn add ../../plugin" ,
7- "reinstall" : " yarn remove anyline-ocr-react-native-module && yarn add ../../plugin" ,
7+ "reinstall" : " yarn remove anyline-ocr-react-native-module && yarn add ../../plugin && node add_license_key.js " ,
88 "start" : " expo start" ,
99 "android" : " expo run:android" ,
1010 "ios" : " expo run:ios --device" ,
Original file line number Diff line number Diff line change @@ -44,13 +44,14 @@ import LicensePlateConfigUS from '../config/LicensePlateConfigUS';
4444import LicensePlateConfigAF from '../config/LicensePlateConfigAF' ;
4545import TINUniversalConfig from '../config/TINUniversalConfig' ;
4646import TINDOTConfig from '../config/TINDOTConfig' ;
47+ const { license } = require ( './license.js' ) ;
4748
4849// Disable Warnings
4950LogBox . ignoreAllLogs ( true ) ;
5051
5152const scrollRef = React . createRef ( ) ;
5253
53- const demoAppLicenseKey = 'REPLACE WITH VALID LICENSE KEY' ;
54+ const demoAppLicenseKey = license ; //replace license key in license.js
5455
5556class Anyline extends Component {
5657 overTheAirUpdateIsEnabled = false ;
You can’t perform that action at this time.
0 commit comments