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

Update to PureScript v0.15.0 #11

4 changes: 2 additions & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"env": { "browser": true, "commonjs": true },
"env": { "browser": true },
"extends": "eslint:recommended",
"parserOptions": { "ecmaVersion": 5 },
"parserOptions": { "ecmaVersion": 6, "sourceType": "module" },
"rules": {
"block-scoped-var": "error",
"consistent-return": "error",
Expand Down
14 changes: 12 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ jobs:
- name: Set up PureScript toolchain
uses: purescript-contrib/setup-purescript@main
with:
purescript: "unstable"
purs-tidy: "latest"

- name: Cache PureScript dependencies
Expand Down Expand Up @@ -49,8 +50,17 @@ jobs:
- name: Build the project
run: npm run build

- name: Run tests
run: npm run test
# - name: Run tests
# run: npm run test

- name: Check formatting
run: purs-tidy check src test

- name: Verify Bower & Pulp
run: |
npm install bower [email protected]
npx bower install
npx pulp build -- --censor-lib --strict
if [ -d "test" ]; then
npx pulp test
fi
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Notable changes to this project are documented in this file. The format is based
## [Unreleased]

Breaking changes:
- Update project and deps to PureScript v0.15.0 (#11 by @JordanMartinez)

New features:

Expand Down
8 changes: 4 additions & 4 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@
"output"
],
"dependencies": {
"purescript-functions": "^5.0.0",
"purescript-maybe": "^5.0.0"
"purescript-functions": "master",
"purescript-maybe": "master"
},
"devDependencies": {
"purescript-assert": "^5.0.0",
"purescript-effect": "^3.0.0"
"purescript-assert": "master",
"purescript-effect": "master"
}
}
2 changes: 1 addition & 1 deletion packages.dhall
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
let upstream =
https://github.com/purescript/package-sets/releases/download/psc-0.14.3-20210722/packages.dhall sha256:1ceb43aa59436bf5601bac45f6f3781c4e1f0e4c2b8458105b018e5ed8c30f8c
https://raw.githubusercontent.com/purescript/package-sets/prepare-0.15/src/packages.dhall

in upstream
10 changes: 4 additions & 6 deletions src/JSURI.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
"use strict";

// A helper which transforms the result ofencodeURIComponent to be compliant
// with RFC3896, as described in the MDN documentation here:
//
Expand All @@ -10,15 +8,15 @@ function toRFC3896(input) {
});
}

exports._encodeURIComponent = function encode(fail, succeed, input) {
export const _encodeURIComponent = function encode(fail, succeed, input) {
try {
return succeed(toRFC3896(encodeURIComponent(input)));
} catch (err) {
return fail(err);
}
};

exports._encodeFormURLComponent = function encode(fail, succeed, input) {
export const _encodeFormURLComponent = function encode(fail, succeed, input) {
try {
return succeed(toRFC3896(encodeURIComponent(input)).replace(/%20/g, "+"));
} catch (err) {
Expand All @@ -34,8 +32,8 @@ function _decodeURIComponent(fail, succeed, input) {
}
}

exports._decodeURIComponent = _decodeURIComponent;
export {_decodeURIComponent};

exports._decodeFormURLComponent = function encode(fail, succeed, input) {
export const _decodeFormURLComponent = function encode(fail, succeed, input) {
return _decodeURIComponent(fail, succeed, input.replace(/\+/g, " "));
};