Skip to content

Commit f690a98

Browse files
committed
docs
1 parent 25324b0 commit f690a98

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

README.md

+7-1
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ Accepts `Object`, `FormData` or `URLSearchParams`.
102102

103103
Specifies which response format will be accepted. Default is `html`.
104104

105-
Options are `html`, `turbo-stream`, `json`.
105+
Options are `html`, `turbo-stream`, `json`, and `script`.
106106

107107
#### Turbo Streams
108108

@@ -115,6 +115,12 @@ window.Turbo = Turbo
115115

116116
Since [v7.0.0-beta.6](https://github.com/hotwired/turbo/releases/tag/v7.0.0-beta.6) Turbo sets `window.Turbo` automatically.
117117

118+
Request.JS will also use Turbo's `fetch` to include the `X-Turbo-Request-ID` header in the request (see [#73](https://github.com/rails/request.js/issues/73)).
119+
120+
#### Script Responses
121+
122+
Request.JS will automatically activate script tags in the response (see [#48](https://github.com/rails/request.js/issues/48)).
123+
118124
#### Request Interceptor
119125

120126
To authenticate fetch requests (eg. with Bearer token) you can use request interceptor. It allows pausing request invocation for fetching token and then adding it to headers:

0 commit comments

Comments
 (0)