Windy Community
    • Unread
    • Categories
    • Groups
    • Go to windy.com
    • Register
    • Login

    [CLOSED] v34.0.0

    Public beta
    5
    11
    2.9k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • vicbV
      vicb Paraglider | Premium
      last edited by vicb

      My plugin calls W.require("favs").getArray() to retrieve the favorites.

      With the beta version W.require("favs").getArray() returns an empty array. However the same code executed from the JS console returns the list of favorites as expected.

      My guess is that the favorites are not initialized at the time of the call by my plugin. What would be the best way to solve this ?

      Edit: I wrapped the call inside a setTimeout(,1000); and it works again with the the beta. This seems to confirm something is not initialized yet.

      marekdM 1 Reply Last reply Reply Quote 0
      • marekdM
        marekd Administrator @vicb
        last edited by marekd

        @vicb I'm not sure why it's behaving differently now, but there have been a lot of changes around users and favorites. In our codes we rely on favsChanged event. I would recommend you to rerender your view on every favsChanged event.

        const favs = W.require('favs');
        
        const render = () => {
            // whatever it should do
        }
        
        favs.on('favsChanged', render);
        render();
        
        // on plugin close you should call favs.off('favsChanged', render);
        

        Hope this helps.

        vicbV 1 Reply Last reply Reply Quote 1
        • vicbV
          vicb Paraglider @marekd | Premium
          last edited by

          @marekd Thanks, it solved my issue.

          It was not too hard (a couple hours) to make my plugin work with both the beta and the stable version.

          Thanks for continuously improving windy !

          1 Reply Last reply Reply Quote 1
          • rittelsR
            rittels Code contributor | Premium
            last edited by rittels

            The compiler at https://github.com/windycom/windy-plugins, does not understand named exports,

            import * as http from '@windy/http' does not work.

            Fortunately import http from '@windy/http' still works.

            The only exception that I could find was: W.map. The leaflet map is at W.map.map, while some custom Windy properties and methods, that were previously added to the leaflet map, are now in W.map, such as baseLayer. (Please correct me if I'm wrong @marekd ).

            marekdM 1 Reply Last reply Reply Quote 0
            • marekdM
              marekd Administrator @rittels
              last edited by

              @rittels It should be import { map } from '@windy/map'. In a case you access the map via W object, you really need to use W.map.map because of named exports. Thanks for pointing it out. I will check the plugin compiler, it should support named exports.

              1 Reply Last reply Reply Quote 0
              • idefix37I
                idefix37 Sailor Moderator
                last edited by idefix37

                @marekd
                ICON-D2 is a very useful addition and new features probably are appreciated by many users too.
                I found some small glitches.

                • ON A FAVORITE LOCATION, near but out of the ICON-D2 domain, the point forecast still shows ICON-D2 model. But forecast is apparently that of ICON-EU as displayed in grey label here:
                  Capture d’écran 2021-10-30 à 18.27.00.png

                Same with all types of meteograms.
                Capture d’écran 2021-10-30 à 18.29.24.png

                • An other small glitch. I chose just for this test the Radar page as starting layer.
                  "Click to change units" is confusing as there is only dBZ unit available with the Radar layer.
                  Then the pulsing blue dot shows a wrong location (50km away) but it is already known. (Why this blue dot is automatically shown with Radar? Couldn't it be possible only when "Find my location" is enabled?)
                  Capture d’écran 2021-10-29 à 14.05.39.png

                • And a minor issue. Some models names in Wind meteogram are cut, specially that of ICON-D2. See first screenshot above

                marekdM 1 Reply Last reply Reply Quote 2
                • marekdM
                  marekd Administrator @idefix37
                  last edited by marekd

                  @idefix37 Thanks for great report and help!

                  • ICON-D2 borders are fixed now
                  • Labels wrapping is fixed now
                  • "Click to change units" has been reported into our bug tracker with lower priority, it is not a release-breaker
                  • Getting your location on desktop is by IP address (or browser info if available), so a minor deviation is fine.

                  Blue dot is shown because we think it is important for radar layer. Typical use case: Will the storm hit me? So you want to know where you are. Of course, it works a little more reliably on devices with GPS.

                  idefix37I 1 Reply Last reply Reply Quote 1
                  • idefix37I
                    idefix37 Sailor Moderator @marekd
                    last edited by

                    @marekd
                    This is perfect.
                    Just a small detail in the Wind table:
                    Capture d’écran 2021-11-03 à 12.55.15.png

                    marekdM 1 Reply Last reply Reply Quote 0
                    • marekdM
                      marekd Administrator @idefix37
                      last edited by

                      @idefix37 Thanks! We're about to go through the whole app and find all overflowing texts. I am pretty sure there will be a similar problem in more places.

                      1 Reply Last reply Reply Quote 1
                      • marekdM marekd locked this topic on
                      • marekdM
                        marekd Administrator
                        last edited by

                        Beta test is closed, v34.0.0 has been released. Thank you all for your help!

                        1 Reply Last reply Reply Quote 1
                        • First post
                          Last post
                        Windyty, S.E. - all rights reserved. Powered by excellent NodeBB
                        NodeBB & contributors, OSM & contributors, HERE maps
                        Terms of Use     Privacy Policy