1
votes

After using FileZilla to ftp the files to the website, my app just shows

Loading....

...when trying to run from a chrome browser.

I have built and tested the app in Webstorm (2017.2.3) Do I need to do anything else other than just copy the files from the build/web directory to my host? What about the build/lib directory? If you want to see what is happening (or not, actually), take a look at: http://sudoku.geobits.com/index.html

Thanks for your help.

1
Any errors in the build output? Just copying over the contents of the build/web folder should be enough. - rinukkusu
Uncaught SyntaxError: Unexpected token ) in main.dart.js explains why it doesn't work, but doesn't explain what's the cause behind. - Emile Bergeron
Thanks. I tried two things, (1) using a browser to open the index.html file in the file system, works perfectly. (2) ran an apache server locally and again it worked perfectly. If you want to take a look, here is the whole WebStorm folder: dropbox.com/s/o9vlay1qeywgmcf/sudoku_03.7z?dl=0 - PSL
I have tried the above on a different computer to a different website, same problem. If I download the uploaded main.dart.js file and attempt to run the web app in a browser using the downloaded file, it doesn't work. i am beginning to suspect the upload is corrupting the file. - PSL
Very possible - are you uploading with FTP? Maybe try setting to binary transfer mode or try it with SFTP instead, if you have that much access to the server. - rinukkusu

1 Answers

1
votes

The file main.dart.js fails to load because of a comment at line 32071:

// "Document", so we check for the xmlVersion property, which is the empty

This is clearly shown in the examples at: sudoku.geobits.com/index.html which loads correctly, compared iwth sudoku.geobits.com/with_comment/index.html which does not. The difference is that the first does not have the comment, whereas the second is the main.dart.js as generated by WebStorm.

I have logged a bug report:#30992 with the dart-sdk people. Thanks to all for their kind help.