New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can Browserslist add a parameter for the current time? #802
Comments
We can add environment variable for that. Please send PR. |
@ai could you give me more details about the environment variable |
Here is section of our docs: https://github.com/browserslist/browserslist#environment-variables And a small brief about the whole idea |
@ai furthermore, have you ever thought about make it can be run in browser? |
@SilentTiger you can use webpack/vite options to set environment variable for client-side bundle. But I don’t think it will be popular to replace current time in browser. |
@ai oh, I mean not only the environment variable in browser, but also the whole Browserslist, thus maybe the https://browsersl.ist/ won't need a backend for query. |
Browserslist supports working in browsers except |
I've added the first commit about this feature, the environment variable has been added, and the "last_years" query has been modified. Can you give me some suggestions, I just want to know if I was on the right way. Thanks. Here is the commit: SilentTiger@23b0373 |
Looks good. Please create PR for deeper analysis. |
Thanks! I think the "last_years" is not the only query that will be affected by this modification, I'll check other queries, and this will take time. |
The configuration of mine is "last 6 years". I am curious to discern the discrepancy between the outcome of executing this query today and the result of conducting the same query the previous year.
It seems a little bit similar to #680
The text was updated successfully, but these errors were encountered: