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

v0.1.14 #67

Merged
merged 1 commit into from
Jan 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## [0.1.14] - 2022-01-03

- avoid TypeError with old app.js

## [0.1.13] - 2022-01-02

- enable JS::Object#await
Expand Down
2 changes: 1 addition & 1 deletion gem/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
bormashino (0.1.13)
bormashino (0.1.14)
json_pure (~> 2.6, >= 2.6.1)
os (~> 1.1, >= 1.1.4)
ruby2_keywords (= 0.0.4)
Expand Down
2 changes: 1 addition & 1 deletion gem/lib/bormashino/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Bormashino
VERSION = '0.1.13'
VERSION = '0.1.14'
end
4 changes: 2 additions & 2 deletions npm/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion npm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "bormashino",
"description": "The package to build SPAs with Ruby",
"homepage": "https://github.com/keyasuda/bormashino",
"version": "0.1.13",
"version": "0.1.14",
"main": "src/index.js",
"scripts": {
"test": "jest --notify src/",
Expand Down
3 changes: 3 additions & 0 deletions npm/src/ruby.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ export const initVmFromRubyModule = async (
}

const requestToServer = async (method, path, payload, referer) => {
if (typeof window.bormashino == 'undefined') {
window.bormashino = {}
}
window.bormashino.requestSrc = JSON.stringify({
method,
path,
Expand Down
2 changes: 1 addition & 1 deletion test-app/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ GIT
PATH
remote: ../gem
specs:
bormashino (0.1.13)
bormashino (0.1.14)
json_pure (~> 2.6, >= 2.6.1)
os (~> 1.1, >= 1.1.4)
ruby2_keywords (= 0.0.4)
Expand Down
6 changes: 3 additions & 3 deletions test-app/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ const main = async () => {
'dispatched: ' + Number(new Date())
})

window.bormashino = RubyApplication
window.rubyVM = vm

const currentPath = () => location.href.replace(location.origin, '')
RubyApplication.request('get', currentPath())
RubyApplication.mount()

window.bormashino = RubyApplication
window.rubyVM = vm
}

main()
2 changes: 1 addition & 1 deletion test-app/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion test-app/spec/test_app_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@
visit 'http://localhost:5000'
loop do
sleep 1
break if page.find(:css, 'h1')
begin
break if page.find(:css, 'h1')
rescue StandardError
end
end
end

Expand Down