Measurement of W$^\pm\gamma$ differential cross sections in proton-proton collisions at $\sqrt{s}$ = 13 TeV and effective field theory constraints