Giter Club home page Giter Club logo

Comments (12)

akhileshgupta avatar akhileshgupta commented on July 26, 2024

Actually the simplest way to run this locally is to just open the file directly in safari via the file path (file:///mobile-ui-elements/simple.html).

Safari allows you to do cross domain request when the web page is loaded from local file system. This also won't be an issue when running inside cordova, as cordova allows that too.

Let me know if you still run into issues.

from mobile-ui-elements.

chexxor avatar chexxor commented on July 26, 2024

I installed Safari and opened the file, but it still shows a blank screen. The JS console doesn't show anything (I haven't used safari dev tools before), so I'm not sure what's going on. I'll read up on it and keep trying, then update this later. The fast response is appreciated!

from mobile-ui-elements.

eoksman avatar eoksman commented on July 26, 2024

Did you disable local file restrictions and add a session token and a
instance URL?

On Tue, Jul 1, 2014 at 7:18 PM, Alex Berg [email protected] wrote:

I installed Safari and opened the file, but it still shows a blank screen.
The JS console doesn't show anything (I haven't used safari dev tools
before), so I'm not sure what's going on. I'll read up on it and keep
trying, then update this later. The fast response is appreciated!


Reply to this email directly or view it on GitHub
#7 (comment)
.

from mobile-ui-elements.

chexxor avatar chexxor commented on July 26, 2024

"disable local file restrictions" - this refers to a thing I do in my OS? Or in Safari?
Yeah - I added those things to the simple.html file.

from mobile-ui-elements.

eoksman avatar eoksman commented on July 26, 2024

Safari. Enable the developer tools, then click on Develop. You'll see it on
the menu

On Tue, Jul 1, 2014 at 8:27 PM, Alex Berg [email protected] wrote:

"disable local file restrictions" - this refers to a thing I do in my OS?
Or in Safari?
Yeah - I added those things to the simple.html file.


Reply to this email directly or view it on GitHub
#7 (comment)
.

from mobile-ui-elements.

chexxor avatar chexxor commented on July 26, 2024

I don't see an option like that in the Develop menu. I checked the Preferences menus for something like that, but nothing appeared. The windows version of Safari must be a bit different from the Mac version.

It looks to be a syntax error on platform.js line 12.

Well, that's ok I guess. Maybe somebody else will come along and figure out this problem. I can still use the custom elements you guys wrote for design ideas at least.

from mobile-ui-elements.

eoksman avatar eoksman commented on July 26, 2024

Ahhh. I assumed you were on a mac. Try Chrome since Safari is using a
fairly old HTML engine.

Launch it from the command line: chrome.exe --disable-web-security

On Tue, Jul 1, 2014 at 8:59 PM, Alex Berg [email protected] wrote:

I don't see an option like that in the Develop menu. I checked the
Preferences menus for something like that, but nothing appeared. The
windows version of Safari must be a bit different from the Mac version.

It looks to be a syntax error on platform.js line 12.

Well, that's ok I guess. Maybe somebody else will come along and figure
out this problem. I can still use the custom elements you guys wrote for
design ideas at least.


Reply to this email directly or view it on GitHub
#7 (comment)
.

from mobile-ui-elements.

akhileshgupta avatar akhileshgupta commented on July 26, 2024

Actually simplified this whole process by adding a node proxy. Just get the latest repo and run following again:

$ npm install
$ bower install
$ node proxy.js

Now open the "http://localhost:9000/simple.html" in the chrome browser without disabling web security. This will now proxy all the salesforce requests through the local node server and hence avoid the CORS issue.

from mobile-ui-elements.

chexxor avatar chexxor commented on July 26, 2024

Hmm, I did what you described, but I'm still getting the same error. I'll look through the code tomorrow. Maybe I'll have better luck after a windows reboot. ;-)

Super appreciate adding a proxy!

from mobile-ui-elements.

eoksman avatar eoksman commented on July 26, 2024

https://sfdc-designer.herokuapp.com/ does this work for you?

On Tue, Jul 1, 2014 at 9:32 PM, Alex Berg [email protected] wrote:

Hmm, I did what you described, but I'm still getting the same error. I'll
look through the code tomorrow. Maybe I'll have better luck after a windows
reboot. ;-)


Reply to this email directly or view it on GitHub
#7 (comment)
.

from mobile-ui-elements.

chexxor avatar chexxor commented on July 26, 2024

Yeah, I was playing with that. Good stuff.
On Jul 2, 2014 12:01 AM, "eoksman" [email protected] wrote:

https://sfdc-designer.herokuapp.com/ does this work for you?

On Tue, Jul 1, 2014 at 9:32 PM, Alex Berg [email protected]
wrote:

Hmm, I did what you described, but I'm still getting the same error.
I'll
look through the code tomorrow. Maybe I'll have better luck after a
windows
reboot. ;-)


Reply to this email directly or view it on GitHub
<
https://github.com/ForceDotComLabs/mobile-ui-elements/issues/7#issuecomment-47736344>

.


Reply to this email directly or view it on GitHub
#7 (comment)
.

from mobile-ui-elements.

chexxor avatar chexxor commented on July 26, 2024

Hey - good news! I tried the proxy server you added to the repo, and it worked today. I'm guessing my sessionId expired the other day. I believe I did try swapping my sessionId at that time, but.... well, it's working now. 👍 Thanks for the help!

Managing an in-browser data-store, connecting to SF, and that kinda stuff is a pain - so I'm excited to build on top of your progress in this area.

from mobile-ui-elements.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.