mirror of
https://github.com/misskey-dev/summaly.git
synced 2025-04-29 02:37:27 +09:00
fix: 次バージョンに向けての記載を追加 (#25)
This commit is contained in:
parent
c261071a82
commit
79d9eadd58
@ -1,3 +1,12 @@
|
||||
5.1.0 / 2024-xx-xx
|
||||
* GETリクエストよりも前にHEADリクエストを送信し、その結果を使用して検証するように (#22)
|
||||
* 下記のパラメータを`summaly`メソッドのオプションに追加
|
||||
- userAgent
|
||||
- responseTimeout
|
||||
- operationTimeout
|
||||
- contentLengthLimit
|
||||
- contentLengthRequired
|
||||
|
||||
5.0.3 / 2023-12-30
|
||||
------------------
|
||||
* Fix .github/workflows/npm-publish.yml
|
||||
|
49
README.md
49
README.md
@ -43,12 +43,17 @@ npm run serve
|
||||
|
||||
#### opts (SummalyOptions)
|
||||
|
||||
| Property | Type | Description | Default |
|
||||
| :------------------ | :--------------------- | :------------------------------ | :------ |
|
||||
| **lang** | *string* | Accept-Language for the request | `null` |
|
||||
| **followRedirects** | *boolean* | Whether follow redirects | `true` |
|
||||
| **plugins** | *plugin[]* (see below) | Custom plugins | `null` |
|
||||
| **agent** | *Got.Agents* | Custom HTTP agent (see below) | `null` |
|
||||
| Property | Type | Description | Default |
|
||||
|:--------------------------|:-----------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:-----------------------|
|
||||
| **lang** | *string* | Accept-Language for the request | `null` |
|
||||
| **followRedirects** | *boolean* | Whether follow redirects | `true` |
|
||||
| **plugins** | *plugin[]* (see below) | Custom plugins | `null` |
|
||||
| **agent** | *Got.Agents* | Custom HTTP agent (see below) | `null` |
|
||||
| **userAgent** | *string* | User-Agent for the request | `SummalyBot/[version]` |
|
||||
| **responseTimeout** | *number* | Set timeouts for each phase, such as host name resolution and socket communication. | `20000` |
|
||||
| **operationTimeout** | *number* | Set the timeout from the start to the end of the request. | `60000` |
|
||||
| **contentLengthLimit** | *number* | If set to true, an error will occur if the content-length value returned from the other server is larger than this parameter (or if the received body size exceeds this parameter). | `10485760` |
|
||||
| **contentLengthRequired** | *boolean* | If set to true, it will be an error if the other server does not return content-length. | `false` |
|
||||
|
||||
#### Plugin
|
||||
|
||||
@ -78,17 +83,17 @@ A Promise of an Object that contains properties below:
|
||||
|
||||
#### SummalyResult
|
||||
|
||||
| Property | Type | Description |
|
||||
| :-------------- | :------- | :------------------------------------------ |
|
||||
| **title** | *string* \| *null* | The title of the web page |
|
||||
| **icon** | *string* \| *null* | The url of the icon of the web page |
|
||||
| **description** | *string* \| *null* | The description of the web page |
|
||||
| **thumbnail** | *string* \| *null* | The url of the thumbnail of the web page |
|
||||
| **sitename** | *string* \| *null* | The name of the web site |
|
||||
| **player** | *Player* | The player of the web page |
|
||||
| **sensitive** | *boolean* | Whether the url is sensitive |
|
||||
| Property | Type | Description |
|
||||
|:----------------|:-------------------|:-----------------------------------------------------------|
|
||||
| **title** | *string* \| *null* | The title of the web page |
|
||||
| **icon** | *string* \| *null* | The url of the icon of the web page |
|
||||
| **description** | *string* \| *null* | The description of the web page |
|
||||
| **thumbnail** | *string* \| *null* | The url of the thumbnail of the web page |
|
||||
| **sitename** | *string* \| *null* | The name of the web site |
|
||||
| **player** | *Player* | The player of the web page |
|
||||
| **sensitive** | *boolean* | Whether the url is sensitive |
|
||||
| **activityPub** | *string* \| *null* | The url of the ActivityPub representation of that web page |
|
||||
| **url** | *string* | The url of the web page |
|
||||
| **url** | *string* | The url of the web page |
|
||||
|
||||
#### Summary
|
||||
|
||||
@ -96,12 +101,12 @@ A Promise of an Object that contains properties below:
|
||||
|
||||
#### Player
|
||||
|
||||
| Property | Type | Description |
|
||||
| :-------------- | :--------- | :---------------------------------------------- |
|
||||
| **url** | *string* \| *null* | The url of the player |
|
||||
| **width** | *number* \| *null* | The width of the player |
|
||||
| **height** | *number* \| *null* | The height of the player |
|
||||
| **allow** | *string[]* | The names of the allowed permissions for iframe |
|
||||
| Property | Type | Description |
|
||||
|:-----------|:-------------------|:------------------------------------------------|
|
||||
| **url** | *string* \| *null* | The url of the player |
|
||||
| **width** | *number* \| *null* | The width of the player |
|
||||
| **height** | *number* \| *null* | The height of the player |
|
||||
| **allow** | *string[]* | The names of the allowed permissions for iframe |
|
||||
|
||||
Currently the possible items in `allow` are:
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@misskey-dev/summaly",
|
||||
"version": "5.0.4",
|
||||
"version": "5.1.0",
|
||||
"description": "Get web page's summary",
|
||||
"author": "syuilo <syuilotan@yahoo.co.jp>",
|
||||
"license": "MIT",
|
||||
|
Loading…
x
Reference in New Issue
Block a user