requestjs-rails 0.0.13 → 0.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a452d308a3c2a875b8aac295997c789ba97655aed5b3bd3d28075b12cd494170
4
- data.tar.gz: b39226e61c2eec6f162a21963ac8a06fa2e800f7232aa8430e16b72a5d6759c2
3
+ metadata.gz: adf29b43dd99b9910bfc96f081f7e8c182b510ab96c21266d2a82c4279041471
4
+ data.tar.gz: 9e145132e9bdb91eb8c6fb5d5e71e7d45ee54b90bada851770363ab4ea3b9a71
5
5
  SHA512:
6
- metadata.gz: 16e03876315812f4506c41d2e65329a4f169d57bd290ecdc301424e7d4bcbc5e3387ed9669be12682bc0147940baa3e9073be3ff231c4f490d780d529635907e
7
- data.tar.gz: '0418aac7b2ee58548edd735bf9b76b7714bcddcca7417e4e19ab5b37dbe23d6283f8556ee84717ac6d7f37bbfb634d7e3134ea7ad87cffff45ab95b348f7fe5f'
6
+ metadata.gz: 84156224aa4fff4c18f76cbe09f764f926ddcdac5caea9414cbb46450e030779017d127b94ca572e3e775dd4959c9d2c2615d3cb8618c608a58342d985dc3950
7
+ data.tar.gz: '08e15d8f20c6e6c57585205ba00353e333212032f6de16b86a1330029a898a101be38bcf92fd688e771ae3cda4fe150caf04ea4b8bab7a5ec995b5a831495b96'
@@ -92,7 +92,7 @@ class RequestInterceptor {
92
92
  function getCookie(name) {
93
93
  const cookies = document.cookie ? document.cookie.split("; ") : [];
94
94
  const prefix = `${encodeURIComponent(name)}=`;
95
- const cookie = cookies.find((cookie => cookie.startsWith(prefix)));
95
+ const cookie = cookies.find(cookie => cookie.startsWith(prefix));
96
96
  if (cookie) {
97
97
  const value = cookie.split("=").slice(1).join("=");
98
98
  if (value) {
@@ -118,7 +118,7 @@ function metaContent(name) {
118
118
  }
119
119
 
120
120
  function stringEntriesFromFormData(formData) {
121
- return [ ...formData ].reduce(((entries, [name, value]) => entries.concat(typeof value === "string" ? [ [ name, value ] ] : [])), []);
121
+ return [ ...formData ].reduce((entries, [name, value]) => entries.concat(typeof value === "string" ? [ [ name, value ] ] : []), []);
122
122
  }
123
123
 
124
124
  function mergeEntries(searchParams, entries) {
@@ -148,7 +148,7 @@ class FetchRequest {
148
148
  } catch (error) {
149
149
  console.error(error);
150
150
  }
151
- const fetch = this.responseKind === "turbo-stream" && window.Turbo ? window.Turbo.fetch : window.fetch;
151
+ const fetch = window.Turbo ? window.Turbo.fetch : window.fetch;
152
152
  const response = new FetchResponse(await fetch(this.url, this.fetchOptions));
153
153
  if (response.unauthenticated && response.authenticationURL) {
154
154
  return Promise.reject(window.location.href = response.authenticationURL);
@@ -1,3 +1,3 @@
1
1
  module Requestjs
2
- VERSION = "0.0.13"
2
+ VERSION = "0.0.14"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: requestjs-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.13
4
+ version: 0.0.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marcelo Lauxen
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-04-30 00:00:00.000000000 Z
10
+ date: 2025-12-11 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: railties