Git Product home page Git Product logo

Comments (11)

tejacques avatar tejacques commented on August 31, 2024

What kind of device are you viewing this on? Could you also give the full error text? crosstab does some UA Sniffing to see if you are on mobile, as any browser environment that freezes tabs not displayed is unsupported. If crosstab detects that something is unsupported, it saves that setting in localStorage and will continue to be unsupported even if you switch emulation modes in chrome.

You need to click "Clear Local Storage Setup Keys" in the demo and refresh the page on standard desktop chrome to have the example work.

from crosstab.

tejacques avatar tejacques commented on August 31, 2024

I took a fresh clone of the repo and run grunt then loaded the demo on Chrome, and it works for me. However looking through the code again, I realized it won't print that a frozen tab environment was detected if it was set in localStorage, so I will update that to report the error correctly.

I strongly suspect this is what happened in your case, but let me know when you get a chance to try it out again.

Thanks for reporting this!

from crosstab.

IAlexanderI avatar IAlexanderI commented on August 31, 2024

Hello. Problem still present.
error in https://github.com/tejacques/crosstab/blob/master/src/crosstab.js#L447
code took data from util.keys.SUPPORTED_KEY - it returns object with some data. object have key "data", if chrome, it return always "false". that means crosstab.supported == false. After that crosstab always says not supported.

Desktop Ubuntu 14.10. Chrome 39.0.2171.95 (64-bit) - latest

from crosstab.

tejacques avatar tejacques commented on August 31, 2024

@IAlexanderI -- could you also give the following information?

  • The error message you receive
  • The user-agent in chrome
  • The steps to reproduce the issue. E.G.:

Thanks

from crosstab.

IAlexanderI avatar IAlexanderI commented on August 31, 2024

User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.95 Safari/537.36

Error message: Error: crosstab not supported: frozen tab environment detected
before was: Error message: Error: crosstab not supported

Error happens when i try send message.
Desktop Ubuntu 14.10. Chrome 39.0.2171.95 (64-bit) - latest
Tested on your sample

from crosstab.

tejacques avatar tejacques commented on August 31, 2024

Were the steps I outlined pretty much exactly what you did? The error you are getting indicates that pinging the master tab timed out, which is how the "frozen tab environment" gets set.

I'll grab an Ubuntu vagrantfile and test later today. For now I would suggest clearing localStorage and reloading to see if the issue goes away.

You can also try bumping up the timeout here: https://github.com/tejacques/crosstab/blob/master/src/crosstab.js#L468-L469 from 100ms to something like 1000ms.

from crosstab.

IAlexanderI avatar IAlexanderI commented on August 31, 2024

Hmm.. I clear localStorage - then all works fine. Thank you.

from crosstab.

tejacques avatar tejacques commented on August 31, 2024

No problem. My best guess for now is that on your initial pageload there was a little bit of lag which caused the ping to time out. I'll keep this issue open for now while I investigate how often this occurs across a variety of different machines and script configurations. It's possible that this is a random event that didn't just affect you.

from crosstab.

IAlexanderI avatar IAlexanderI commented on August 31, 2024

Another question. How can i use library, without angular.

from crosstab.

tejacques avatar tejacques commented on August 31, 2024

You don't need to use angular, the example page just uses it since that was an easy way to whip up a test page.

You can look here for a quick overview: https://github.com/tejacques/crosstab#api

Here's a very quick example:

crosstab.on('testEvent', function(message) {
    console.log('tab: ' + message.origin + ', message: ' + message.data);
});

crosstab.broadcast('testEvent', 'testMessage');

output

tab: 14255739976781973682913, message: testMessage

from crosstab.

tejacques avatar tejacques commented on August 31, 2024

The timeout doesn't seem to be an issue in further testing, so for now I'm closing this.

from crosstab.

Related Issues (20)

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.