简体   繁体   中英

How to use History.js with GWT?

I want to use History.js from Google Web Toolkit.

I know GWT has History functionality of it's own, but I don't like it because it uses the hashes in the URI, I want to use the new HTML5 History API as much as possible.

The only current way that I can think of to run History.js and GWT together is to write the History.js part in plain Javascript (or jQuery) and then manually call a GWT method.

It would be nice if it was possible to use the whole History.js functionality from within GWT's Java files.

No pain at all with that .

You just simple add your History js file on your document and you can use it .

Here i answered how you can use an external js in GWT .

Using externel js in GWT

After you call the native method you can continue with gwt method

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM