Fix version number in playground (#5372)

## Summary

`v0.0.275` in the top-right was showing `v0.0.0` at all times.

## Test Plan

![Screen Shot 2023-06-26 at 11 31 16
AM](e6cd0e19-6a5f-4b46-a060-54f492524737)
This commit is contained in:
Charlie Marsh 2023-06-26 11:56:12 -04:00 committed by GitHub
parent 2fc38d81e6
commit 8a1bb7a5af
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View file

@ -9,6 +9,8 @@ pub use ruff_python_ast::source_code::round_trip;
pub use rule_selector::RuleSelector;
pub use rules::pycodestyle::rules::IOError;
pub const VERSION: &str = env!("CARGO_PKG_VERSION");
mod autofix;
mod checkers;
mod codes;

View file

@ -21,8 +21,6 @@ use ruff::settings::{defaults, flags, Settings};
use ruff_diagnostics::Edit;
use ruff_python_ast::source_code::{Indexer, Locator, SourceLocation, Stylist};
const VERSION: &str = env!("CARGO_PKG_VERSION");
#[wasm_bindgen(typescript_custom_section)]
const TYPES: &'static str = r#"
export interface Diagnostic {
@ -87,7 +85,7 @@ pub fn run() {
#[wasm_bindgen]
#[allow(non_snake_case)]
pub fn currentVersion() -> JsValue {
JsValue::from(VERSION)
JsValue::from(ruff::VERSION)
}
#[wasm_bindgen]