Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 07a4d82

Browse files
committedJul 8, 2020
Print used isort versin to console for live editor, use black profile by default
1 parent 25f2b5c commit 07a4d82

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed
 

‎docs/quick_start/0.-try.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ import b, a
3535
&nbsp;Configuration (Note: the below must follow JSON format). Full configuration guide is <a href="https://timothycrosley.github.io/isort/docs/configuration/options/">here</a>:
3636

3737
<div id="configEditor" class="configurator">{"line_length": 80,
38-
"multi_line_output": 2,
38+
"profile": "black",
3939
"atomic": true
4040
}
4141
</div>

‎docs/quick_start/interactive.js

+3-4
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ window.addEventListener('load', () => {
2626
languagePluginLoader.then(() => {
2727
return pyodide.loadPackage(['micropip'])
2828
}).then(() => {
29-
console.log(pyodide.runPython('import sys\nsys.version'));
30-
console.log(pyodide.runPython('print(1 + 2)'));
3129
pyodide.runPython(`
3230
import micropip
3331
@@ -37,7 +35,8 @@ def use_isort(*args):
3735
import isort
3836
import json
3937
import textwrap
40-
print(isort.code("import b; import a"))
38+
39+
print(f"Using {isort.__version__} of isort.")
4140
4241
def sort_code(code, configuration):
4342
try:
@@ -52,5 +51,5 @@ def use_isort(*args):
5251
document.sort_code = sort_code
5352
document.updateOutput()
5453
55-
micropip.install('https://timothycrosley.github.io/isort/docs/quick_start/isort-5.0.1-py3-none-any.whl').then(use_isort)`);
54+
micropip.install('isort').then(use_isort)`);
5655
});

0 commit comments

Comments
 (0)
Please sign in to comment.