Skip to content

Commit 60b4759

Browse files
authored
Merge pull request #2216 from beautify-web/staging/release
Pulling staging/release into release
2 parents 11e21b0 + 340b577 commit 60b4759

37 files changed

+727
-268
lines changed

.github/dependabot.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: "npm" # See documentation for possible values
9+
directory: "/" # Location of package manifests
10+
schedule:
11+
interval: "weekly"
12+
open-pull-requests-limit: 15
13+
- package-ecosystem: "pip" # See documentation for possible values
14+
directory: "/python" # Location of package manifests
15+
schedule:
16+
interval: "weekly"
17+
open-pull-requests-limit: 15
18+
- package-ecosystem: "github-actions"
19+
directory: "/"
20+
schedule:
21+
# Check for updates to GitHub Actions every week
22+
interval: "weekly"
23+
open-pull-requests-limit: 15

.github/workflows/codeql-analysis.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,11 @@ jobs:
3535

3636
steps:
3737
- name: Checkout repository
38-
uses: actions/checkout@v2
38+
uses: actions/checkout@v4
3939

4040
# Initializes the CodeQL tools for scanning.
4141
- name: Initialize CodeQL
42-
uses: github/codeql-action/init@v1
42+
uses: github/codeql-action/init@v2
4343
with:
4444
languages: ${{ matrix.language }}
4545
# If you wish to specify custom queries, you can do so here or in a config file.
@@ -50,7 +50,7 @@ jobs:
5050
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
5151
# If this step fails, then you should remove it and run the build manually (see below)
5252
- name: Autobuild
53-
uses: github/codeql-action/autobuild@v1
53+
uses: github/codeql-action/autobuild@v2
5454

5555
# ℹ️ Command-line programs to run using the OS shell.
5656
# 📚 https://git.io/JvXDl
@@ -64,4 +64,4 @@ jobs:
6464
# make release
6565

6666
- name: Perform CodeQL Analysis
67-
uses: github/codeql-action/analyze@v1
67+
uses: github/codeql-action/analyze@v2

.github/workflows/main.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,17 @@ jobs:
2626
- python-version: 3.11
2727
node-version: 20
2828
steps:
29-
- uses: actions/checkout@v2
29+
- uses: actions/checkout@v4
3030
- name: Set up Node ${{ matrix.node-version }}
31-
uses: actions/setup-node@v1
31+
uses: actions/setup-node@v4
3232
with:
3333
node-version: ${{ matrix.node-version }}
3434
- name: Set up Python ${{ matrix.python-version }}
35-
uses: actions/setup-python@v2
35+
uses: actions/setup-python@v4
3636
with:
3737
python-version: ${{ matrix.python-version }}
3838
- name: Cached node_modules
39-
uses: actions/cache@v2
39+
uses: actions/cache@v3
4040
with:
4141
path: node_modules
4242
key: ${{ runner.os }}-node-${{ hashFiles('**/package*.json') }}

.github/workflows/milestone-publish.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,18 @@ jobs:
1212
publish:
1313
runs-on: ubuntu-latest
1414
steps:
15-
- uses: actions/checkout@v2
15+
- uses: actions/checkout@v4
1616
with:
1717
fetch-depth: 0
1818
- name: Set up Node
19-
uses: actions/setup-node@v1
19+
uses: actions/setup-node@v4
2020
with:
21-
node-version: 14
21+
node-version: 18
2222
registry-url: https://registry.npmjs.org/
2323
- name: Set up Python
24-
uses: actions/setup-python@v2
24+
uses: actions/setup-python@v4
2525
with:
26-
python-version: 3.8
26+
python-version: 3.11
2727
- name: Set git user
2828
run: |
2929
git config --global user.email "[email protected]"

.github/workflows/pr-staging.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
PR-from-staging:
1616
runs-on: ubuntu-latest
1717
steps:
18-
- uses: actions/checkout@v2
18+
- uses: actions/checkout@v4
1919
with:
2020
fetch-depth: 0
2121
- name: pull-request gh-pages

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Changelog
22

3+
## v1.14.10
4+
* Editor not working https://beautifier.io/ ([#2201](https://github.com/beautify-web/js-beautify/issues/2201))
5+
* Set nodejs minimum to v14 ([#2169](https://github.com/beautify-web/js-beautify/pull/2169))
6+
* Invalid prettification of object with unicode escape character as object key ([#2159](https://github.com/beautify-web/js-beautify/issues/2159))
7+
* invalid json being generated with wrap\_line\_length ([#1932](https://github.com/beautify-web/js-beautify/issues/1932))
8+
39
## v1.14.9
410
* Bump semver and editorconfig ([#2161](https://github.com/beautify-web/js-beautify/pull/2161))
511
* Update editorconfig package ([#2160](https://github.com/beautify-web/js-beautify/issues/2160))

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ Fixes and enhancements are totally welcome. We prefer you to file an issue befo
1111

1212
* bash
1313
* make
14-
* nodejs - v10.x (with npm)
15-
* python - v2.7.x or v3.x (with pip)
14+
* nodejs - v16.x or greater (with npm)
15+
* python - v3.7 or greater (with pip)
1616

1717
If you encounter issues and cannot build, come chat on gitter.im. We're happy to help.
1818

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,13 @@ JS Beautifier is hosted on two CDN services: [cdnjs](https://cdnjs.com/libraries
5858

5959
To pull the latest version from one of these services include one set of the script tags below in your document:
6060
```html
61-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.9/beautify.js"></script>
62-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.9/beautify-css.js"></script>
63-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.9/beautify-html.js"></script>
61+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.10/beautify.js"></script>
62+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.10/beautify-css.js"></script>
63+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.10/beautify-html.js"></script>
6464

65-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.9/beautify.min.js"></script>
66-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.9/beautify-css.min.js"></script>
67-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.9/beautify-html.min.js"></script>
65+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.10/beautify.min.js"></script>
66+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.10/beautify-css.min.js"></script>
67+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.10/beautify-html.min.js"></script>
6868
```
6969

7070
Example usage of a JS tag in html:
@@ -76,7 +76,7 @@ Example usage of a JS tag in html:
7676

7777
. . .
7878

79-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.9/beautify.min.js"></script>
79+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.10/beautify.min.js"></script>
8080
<script src="script.js"></script>
8181
</body>
8282
</html>
@@ -434,4 +434,4 @@ Thanks also to Jason Diamond, Patrick Hof, Nochum Sossonko, Andreas Schneider, D
434434
Vasilevsky, Vital Batmanov, Ron Baldwin, Gabriel Harrison, Chris J. Shull,
435435
Mathias Bynens, Vittorio Gambaletta and others.
436436
437-
(README.md: [email protected].9)
437+
(README.md: [email protected].10)

index.html

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -38,25 +38,25 @@
3838
<script src="https://cdn.polyfill.io/v2/polyfill.min.js?features=default&flags=gated"></script>
3939

4040
<!-- Codemirror from https://cdnjs.com/libraries/codemirror -->
41-
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/codemirror.min.css" integrity="sha256-vZ3SaLOjnKO/gGvcUWegySoDU6ff33CS5i9ot8J9Czk=" crossorigin="anonymous" />
42-
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/theme/darcula.min.css" integrity="sha256-ZzdkdGSdYSUv4R77x7A5G7EeFDLMhAiCybNBNxNoxos=" crossorigin="anonymous" />
43-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/codemirror.min.js" integrity="sha256-dPTL2a+npIonoK5i0Tyes0txCMUWZBf8cfKRfACRotc=" crossorigin="anonymous"></script>
41+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/codemirror.min.css" integrity="sha512-9VgBnmEYUpZ041Fz5LvsEsFlEzAlUw6Ku5uPhNSKgqY4DgM+g8BRoYvfbfDcTqs3BPsREBB3ccVVlkCSLZ5T+Q==" crossorigin="anonymous" referrerpolicy="no-referrer" />
42+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/theme/darcula.min.css" integrity="sha512-gFMl3u9d0xt3WR8ZeW05MWm3yZ+ZfgsBVXLSOiFz2xeVrZ8Neg0+V1kkRIo9LikyA/T9HuS91kDfc2XWse0K0A==" crossorigin="anonymous" referrerpolicy="no-referrer" />
43+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/codemirror.min.js" integrity="sha512-wQgeja/1fclPgUWIHnv/MVPCdiL56SK0P8zLgtpOMhUYtvpaZTr/Q/IV2gkvzEYvMc3ZY2PaxarEj0m3CkOtfw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
4444

4545
<!-- Codemirror Modes -->
46-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/xml/xml.min.js" integrity="sha256-cphnEddX56MtGJsi1PoCPLds+dlnDj1QQkAlCWeJYDo=" crossorigin="anonymous"></script>
47-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/javascript/javascript.min.js" integrity="sha256-7AjEsHnW7cpq2raC/uxnGCP2G4zIKmCdz7OAv6LN00o=" crossorigin="anonymous"></script>
48-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/css/css.min.js" integrity="sha256-mjhvNBMExwa2AtP0mBlK9NkzJ7sgRSyZdgw9sPhhtb0=" crossorigin="anonymous"></script>
49-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/htmlmixed/htmlmixed.min.js" integrity="sha256-qfS6ZUe6JhPU75/Sc1ftiWzC2N9IxGEjlRwpKB78Ico=" crossorigin="anonymous"></script>
46+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/xml/xml.min.js" integrity="sha512-KU6R9MYnyy7/YS6zdRhTpYZJqQmBSEywURvPS9yqLNEXVU/LSkVupFYzekqKmERPF6KQmg1cYlDg+pCOZu3sZQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
47+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/javascript/javascript.min.js" integrity="sha512-KRFhN4NY/FfTI0TMPLc2r4iBUOt236/wm5VAIIOMM7s4SJIzErvkwihZb/IyKBJSbUSd4vIcBF8k36TNiCy4DA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
48+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/css/css.min.js" integrity="sha512-iuxJGOUjCTxOwTeDzLXgima4Q5r6o88tr2GsvmgfSmiqDULC74q5izBnbHG32uOPYnyTL35mmlPGCkaI0Mu0Ww==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
49+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/mode/htmlmixed/htmlmixed.min.js" integrity="sha512-MdDU7KJqREsJm/eOi90N7J/IoYJ81KBhOlgmZmaQNA4i6RksXbffJNywmx3KNlrBQoVRlMnE2mnqJ4VOe2SsEQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
5050

51-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/search/search.js" integrity="sha256-iUnNlgkrU5Jj8oKl2zBBCTmESI2xpXwZrTX+arxSEKc=" crossorigin="anonymous"></script>
52-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/search/searchcursor.min.js" integrity="sha256-y7nxCQ9bT6p4fEq9ylGxWfMQBpL6ingXkav6Nr1AcZ8=" crossorigin="anonymous"></script>
53-
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/dialog/dialog.min.js" integrity="sha256-G+QhvxjUNi5P5cyQqjROwriSUy2lZtCFUQh+8W1o6I0=" crossorigin="anonymous"></script>
54-
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/dialog/dialog.css" integrity="sha256-XfaQ13HxIRg0hWLdKpAGBDOuLt7M0JCKvKpEgLHj5Gg=" crossorigin="anonymous" />
51+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/search/search.js" integrity="sha512-sHa7Nz2KixDnwwCdtjxUbu4yYsWXNAgto8LNbhrA693xGS12P1/90gdnd837EzBrNg8Suazc70BlFDQIO1qW7w==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
52+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/search/searchcursor.min.js" integrity="sha512-bUUEt0Ckb4QlT1n1+PiNzNcYbWRWLO0iUfvYSYJaAFkmL/VKwrI7HFnSQxAwhtM6Cbd9JDb1RMEaT1aW6PZ1nA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
53+
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/dialog/dialog.min.js" integrity="sha512-WYctQXRN2KbvUe9S67mXvptV2/hGKIKHx14FVbI3Uk4ClGxqnzRxl9pS2A99DhW9kzkWLn+qLwNmhhReJZiOFQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
54+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.48.4/addon/dialog/dialog.css" integrity="sha512-5/XbSvrM+KAMENYsNpNkIyPT/PF2BKR5eAPfBOTxRKlE3GRsL9ogVI31OK2ndVcBJ7KhVAOZahcc7RdpaX8+5A==" crossorigin="anonymous" referrerpolicy="no-referrer" />
5555

56-
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.min.js" integrity="sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0=" crossorigin="anonymous"></script>
56+
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.min.js" integrity="sha512-bLT0Qm9VnAYZDflyKcBaQ2gg0hSYNQrJ8RilYldYQ1FxQYoCLtUjuuRuZo+fjqhx/qtq/1itJ0C2ejDxltZVFg==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
5757

58-
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-cookie/2.2.1/js.cookie.min.js" integrity="sha256-oE03O+I6Pzff4fiMqwEGHbdfcW7a3GRRxlL+U49L5sA=" crossorigin="anonymous"></script>
59-
<script src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.6/require.min.js" integrity="sha256-1fEPhSsRKlFKGfK3eO710tEweHh1fwokU5wFGDHO+vg=" crossorigin="anonymous"></script>
58+
<script src="https://cdnjs.cloudflare.com/ajax/libs/js-cookie/2.2.1/js.cookie.min.js" integrity="sha512-Meww2sXqNHxI1+5Dyh/9KAtvI9RZSA4c1K2k5iL02oiPO/RH3Q30L3M1albtqMg50u4gRTYdV4EXOQqXEI336A==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
59+
<script src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.6/require.min.js" integrity="sha512-c3Nl8+7g4LMSTdrm621y7kf9v3SDPnhxLNhcjFJbKECVnmZHTdo+IRO05sNLTH/D3vA6u1X32ehoLC7WFVdheg==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
6060

6161
<script src="js/lib/unpackers/javascriptobfuscator_unpacker.js"></script>
6262
<script src="js/lib/unpackers/urlencode_unpacker.js"></script>
@@ -158,7 +158,7 @@ <h2>Options</h2>
158158
<label for="comma-first">Use comma-first list style?</label>
159159
<br>
160160
<input class="checkbox" type="checkbox" id="detect-packers">
161-
<label for="detect-packers">Detect packers and obfuscators?</label>
161+
<label for="detect-packers">Detect packers and obfuscators? (unsafe)</label>
162162
<br>
163163
<input class="checkbox" type="checkbox" id="brace-preserve-inline">
164164
<label for="brace-preserve-inline">Preserve inline braces/code blocks?</label>

js/lib/beautifier.js

Lines changed: 21 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)