Giter VIP home page Giter VIP logo

Comments (10)

bjornharrtell avatar bjornharrtell commented on September 26, 2024

I've got a patch for it, but it's not good enough for PR as it forces IE11 as a target which may or may not be what is wanted.. in your case it may be what you want :) See master...bjornharrtell:ie11

from ol-mapbox-style.

ahocevar avatar ahocevar commented on September 26, 2024

Adding a Symbol polyfill should also fix the issue. The examples add polyfills already, so you could just change the line in the html to

  <script src="https://cdn.polyfill.io/v2/polyfill.min.js?features=Promise,Symbol"></script>

A pull request which changes that in all exmaples would be welcome.

from ol-mapbox-style.

tds4u avatar tds4u commented on September 26, 2024

Added "Symbol" but now another error (translated from german). Search for "},{}],6:[function(require,module,exports){" to find right line.
Object does not support property or method "undefined"

                _iterator.return();
            }
        } finally {
            if (_didIteratorError) {
                throw _iteratorError;    <<<=== error
            }
        }
    }

    return output;
};

},{}],6:[function(require,module,exports){
'use strict';

from ol-mapbox-style.

ahocevar avatar ahocevar commented on September 26, 2024

Ok, then you also need the Symbol.iterator polyfill:

<script src="https://cdn.polyfill.io/v2/polyfill.min.js?features=Promise,Symbol,Symbol.iterator"></script>

from ol-mapbox-style.

tds4u avatar tds4u commented on September 26, 2024

Didn't work => "Object expected"

from ol-mapbox-style.

bjornharrtell avatar bjornharrtell commented on September 26, 2024

Apparently polyfill with feature set "Promise,Symbol,Array.prototype.@@iterator" works.

from ol-mapbox-style.

ahocevar avatar ahocevar commented on September 26, 2024

Thanks @bjornharrtell, can you submit a pull request please?

@tds4u If you build your application together with all dependencies (which is recommended anyway), you can configure Babel accordingly and will not be affected by this.

from ol-mapbox-style.

tds4u avatar tds4u commented on September 26, 2024

@bjornharrtell That worked !!! Thanks
@ahocevar Can you tell us how?

from ol-mapbox-style.

bjornharrtell avatar bjornharrtell commented on September 26, 2024

Done at #43 but only for the example in question. Will need to revisit later if want to have the same polyfill for all examples.

from ol-mapbox-style.

ahocevar avatar ahocevar commented on September 26, 2024

@tds4u Use the ol package and follow the instructions there. I prefer the Webpack & Uglify method. When targeting IE11, it may be better to use babel-minify instead of Uglify, since you'll be using Babel anyway.

from ol-mapbox-style.

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.