Skip to content

Commit

Permalink
docs: improve codeblocks
Browse files Browse the repository at this point in the history
  • Loading branch information
imranbarbhuiya committed Jul 31, 2022
1 parent bd1fa9a commit 1f536a0
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 16 deletions.
6 changes: 3 additions & 3 deletions packages/tagscript-plugin-discord/src/lib/Parsers/Cooldown.ts
Expand Up @@ -9,15 +9,15 @@ import { BaseParser, type Context, type IParser } from 'tagscript';
*
* @usage
* ```yaml
* {cooldown(seconds):response}
* { cooldown(seconds): response }
* ```
*
* @alias cd
*
* @example
* ```yaml
* {cooldown(5):This tag is on cooldown.}
* {cooldown(5):The tag {name} is on cooldown. Please try again in {retryAfter}.}
* { cooldown(5): This tag is on cooldown. }
* { cooldown(5): The tag {name} is on cooldown. Please try again in {retryAfter}. }
* ```
*
*/
Expand Down
24 changes: 12 additions & 12 deletions packages/tagscript-plugin-discord/src/lib/Parsers/Embed.ts
Expand Up @@ -11,30 +11,30 @@ import type { EmbedData, APIEmbed } from 'discord.js';
* Using JSON
* @usage
* ```yaml
* {embed:json}
* { embed: json }
* ```
* @example
* ```yaml
* {embed:{"title":"Hello!", "description":"This is a test embed."}}
* {embed:{
* "title":"Here's a random duck!",
* "image":{"url":"https://random-d.uk/api/randomimg"},
* "color":15194415
* }}
* { embed: { "title": "Hello!", "description": "This is a test embed." } }
* { embed: {
* "title": "Here's a random duck!",
* "image": { "url": "https://random-d.uk/api/randomimg" },
* "color": 15194415
* } }
* ```
*
* Using properties
* @usage
* ```yaml
* {embed(property):value}
* { embed(property): value }
* ```
*
* @example
* ```yaml
* {embed(color):0x37b2cb}
* {embed(title):Rules}
* {embed(description):Follow these rules to ensure a good experience in our server!}
* {embed(field):Rule 1|Respect everyone you speak to.|false}
* { embed(color): 0x37b2cb }
* { embed(title): Rules }
* { embed(description): Follow these rules to ensure a good experience in our server! }
* { embed(field): Rule 1|Respect everyone you speak to.|false }
* ```
*
* @see The return type depends on user's input. So it might not be `EmbedData | APIEmbed`. So use a typeguard to check.
Expand Down
3 changes: 2 additions & 1 deletion typedoc.json
Expand Up @@ -7,5 +7,6 @@
"name": "TagScript",
"out": "./docs/",
"tsconfig": "./tsconfig.base.json",
"externalLinkPath": "scripts/externalConfig.js"
"externalLinkPath": "scripts/externalConfig.js",
"hideGenerator": true
}

0 comments on commit 1f536a0

Please sign in to comment.