Search code examples
oracle-jet

Oracle Jet: Unable to make hybrid app with Ojet cli 9.1


I am trying to build a hybrid app using ojet and ojet-cli. I am referring the getting started page on the official ojet site.

I can successfully scafold web app using the ojet-cli and serve it but when I type the command ojet add hybrid I get the below error

   {
  code: 'ERR_INVALID_ARG_TYPE',
  message: '(during updateConfigXml) The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Document'
}

Below is the complete log from my console

~/Desktop/testApp                                                                                                               ⍉
▶ ojet add hybrid
? Please choose the platforms you want to install iOS
Adding platform: ios
Using cordova-fetch for cordova-ios@^6.1.0


Adding ios project...


Creating Cordova project for the iOS platform:
    Path: platforms/ios

    Package: org.oraclejet.testapp
    Name: testApp

iOS project created with [email protected]

Discovered plugin "cordova-plugin-whitelist". Adding it to the project


Installing "cordova-plugin-whitelist" for ios

Adding cordova-plugin-whitelist to package.json


Adding platform: browser
Using cordova-fetch for cordova-browser@^6.0.0


Adding browser project...

Creating Cordova project for cordova-browser:
    Path: /Users/hellonuh/Desktop/testApp/hybrid/platforms/browser

    Name: testApp

Installing "cordova-plugin-whitelist" for browser

6.0.0

{
  code: 'ERR_INVALID_ARG_TYPE',
  message: '(during updateConfigXml) The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Document'
}

Below are my environment details

├── @oracle/[email protected]
├── [email protected]
└── [email protected]

▶ node -v
v14.5.0


Solution

  • Please drop your Node version down to the LTS release and try again. We always see issues when people are using the "current" release of Node.