0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

TypeScriptである文字数の文字列を生成する

Posted at

文字数制限をテストするために適当な文字列が欲しい場合

"a".repeat(1000)

"a"を1000回足し合わせている

ちょろっと調べても出てこなかったので、string型で適当に探してたら発見した
(この書き方はkotlinでもできる)

ランダム生成ではないが、文字数制限だけをテストしたいのであればこれで十分そう

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?