Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Developer
DueNorth
Posts: 135
Registered: ‎09-25-2012
My Device: Dev Alpha
Accepted Solution

Uncaught SyntaxError: Unexpected end of input ... with Webworks-1.0.2.9.js:1178 & BBUI-0.9.4.js

Super strange, so I am trying to integrate the new BBUI-0.9.4.js code.

 

The initialization code for BBUI.js has changed to include Webworks so I tried it and started getting:

I tried it on a blank app and still I am getting the error.

config.xml

<?xml version="1.0" encoding="utf-8"?>
<widget xmlns="http://www.w3.org/ns/widgets" 
   xmlns:rim="http://www.blackberry.com/ns/widgets" 
   version="1.0.0.0" id="Test" rim:header="Test">
   <rim:navigation mode="focus" />
   <name>Test</name>
   <description>Test desc</description>
   <author rim:copyright="2012" email="test@test.com">Test</author>
	<feature id="blackberry.system.event" />
	<feature id="blackberry.app" />
	<feature id="blackberry.app.event" />
    <content src="index.html"/>    
</widget>

 index.html

  <html>
      <head>
          <link  rel="stylesheet" type="text/css" href="bbui-0.9.4.css"></link>
          <script type="text/javascript" src="bbui-0.9.4.js"></script>
          <script type="text/javascript" src="js/webworks-1.0.2.9.js"></script>
          <script type="text/javascript">
          document.addEventListener('webworksready', function(e) {
              bb.init();
              // Open our first screen
              bb.pushScreen('home.html', 'home');			  
          }, false);
          </script>
      </head>
      <body>
      </body>
  </html>

 

Just in case, I redownloaded the SDK. Grabbed the version of webworks from the Framework > ClientFiles. That didn't do anything because the file is the same.

 

I am using: Ripple UI (v0.9.10), Ripple Build & Deploy (v0.9.5).


I feel like I am missing something perhaps obvious. Any clue what I am doing wrong?

Please use plain text.
Retired
erikjohnzon
Posts: 245
Registered: ‎09-21-2012
My Device: Q10

Re: Uncaught SyntaxError: Unexpected end of input ... with Webworks-1.0.2.9.js:1178 & BBUI-0.9.4.js

Hey DueNorth,

 

That error is usually the case when webworks extensions cannot be loaded. Either your localhost protocol is blocking the request in chrome or something to this effect. It has nothing to do with the actual webworks file (I hope) but when it is trying to load the extensions themselves. Some of these links migh thelp you:

 

https://github.com/blackberry/Ripple-UI/issues/603

https://github.com/blackberry/BB10-WebWorks-Framework/issues/289

 

@erikjohnzon
erjohnson@blackberry.com
Please use plain text.
BlackBerry Development Advisor
anzor_b
Posts: 165
Registered: ‎09-24-2012
My Device: Passport

Re: Uncaught SyntaxError: Unexpected end of input ... with Webworks-1.0.2.9.js:1178 & BBUI-0.9.4.js

Hi DueNorth,

 

This issue is cosmetic and can be ignored. It's trying to query an extension on the device, but it's running on your computer, so it returns an error. Our development team is working on getting it resolved for a future release.

 

Thank you for your patience.

Please use plain text.