Skip to content
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

createStreaming function freezes during execution #7

Open
scarf005 opened this issue Mar 3, 2023 · 0 comments
Open

createStreaming function freezes during execution #7

scarf005 opened this issue Mar 3, 2023 · 0 comments

Comments

@scarf005
Copy link

scarf005 commented Mar 3, 2023

Summary

createStreaming takes forever when running example code from deno.land

import {
  createStreaming,
  GlobalConfiguration,
} from "https://deno.land/x/dprint/mod.ts"

const globalConfig: GlobalConfiguration = {
  indentWidth: 2,
  lineWidth: 80,
}
const tsFormatter = await createStreaming(
  // check https://plugins.dprint.dev/ for latest plugin versions
  fetch("https://plugins.dprint.dev/typescript-0.57.0.wasm"),
)

tsFormatter.setConfig(globalConfig, {
  semiColons: "asi",
})

// outputs: "const t = 5\n"
console.log(tsFormatter.formatText("file.ts", "const   t    = 5;"))

System version

deno --version
deno 1.31.1 (release, x86_64-unknown-linux-gnu)
v8 11.0.226.13
typescript 4.9.4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant