Repository: dubzzz/fast-check
Pull request #1802 (2021-04-27 18:37:28)

🚚 Move string arbitraries into /arbitrary
<!-- Why is this PR for? -->
<!-- Describe the reason why you opened this PR or give a link towards the associated issue. -->

## In a nutshell

❌ New feature
❌ Fix an issue
❌ Documentation improvement
✔️ Other: *moving files*

(✔️: yes, ❌: no)

## Potential impacts

None


codesandbox[bot]: This pull request is automatically built and testable in [CodeSandbox](https://codesandbox.io).

  To see build info of the built libraries, click [here](https://ci.codesandbox.io/status/dubzzz/fast-check/pr/1802/builds/124508) or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 01515d8eeea5f79fdae4a2b1a7d0f970642a4ce0:

|Sandbox| Source |
|--|--|
|[Vanilla](https://codesandbox.io/s/vanilla-thjqk)| Configuration |

codecov[bot]: # [Codecov](https://codecov.io/gh/dubzzz/fast-check/pull/1802?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) Report
> Merging [#1802](https://codecov.io/gh/dubzzz/fast-check/pull/1802?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) (01515d8) into [main](https://codecov.io/gh/dubzzz/fast-check/commit/22b32163aecc5e1130d43cede869658c95c8de94?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) (22b3216) will **increase** coverage by `0.02%`.
> The diff coverage is `97.93%`.

[![Impacted file tree graph](https://codecov.io/gh/dubzzz/fast-check/pull/1802/graphs/tree.svg?width=650&height=150&src=pr&token=fRi2fJN730&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN)](https://codecov.io/gh/dubzzz/fast-check/pull/1802?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN)

```diff
@@            Coverage Diff             @@
##             main    #1802      +/-   ##
==========================================
+ Coverage   97.24%   97.26%   +0.02%     
==========================================
  Files         129      139      +10     
  Lines        3740     3772      +32     
  Branches      740      740              
==========================================
+ Hits         3637     3669      +32     
  Misses         99       99              
  Partials        4        4              
```

| Flag | Coverage Δ | |
|---|---|---|
| unit-tests | `97.26% <97.93%> (+0.02%)` | :arrow_up: |
| unit-tests-10.x-Linux | `?` | |
| unit-tests-12.x-Linux | `?` | |
| unit-tests-14.x-Linux | `97.26% <97.93%> (+0.02%)` | :arrow_up: |

Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#carryforward-flags-in-the-pull-request-comment) to find out more.

| [Impacted Files](https://codecov.io/gh/dubzzz/fast-check/pull/1802?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) | Coverage Δ | |
|---|---|---|
| [src/arbitrary/fullUnicodeString.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9mdWxsVW5pY29kZVN0cmluZy50cw==) | `60.00% <60.00%> (ø)` | |
| [...internals/builders/Base64StringArbitraryBuilder.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9faW50ZXJuYWxzL2J1aWxkZXJzL0Jhc2U2NFN0cmluZ0FyYml0cmFyeUJ1aWxkZXIudHM=) | `100.00% <100.00%> (ø)` | |
| [...rary/\_internals/builders/StringArbitraryBuilder.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9faW50ZXJuYWxzL2J1aWxkZXJzL1N0cmluZ0FyYml0cmFyeUJ1aWxkZXIudHM=) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/\_internals/mappers/StringToBase64.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9faW50ZXJuYWxzL21hcHBlcnMvU3RyaW5nVG9CYXNlNjQudHM=) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/asciiString.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9hc2NpaVN0cmluZy50cw==) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/base64String.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9iYXNlNjRTdHJpbmcudHM=) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/hexaString.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9oZXhhU3RyaW5nLnRz) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/string.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9zdHJpbmcudHM=) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/string16bits.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9zdHJpbmcxNmJpdHMudHM=) | `100.00% <100.00%> (ø)` | |
| [src/arbitrary/stringOf.ts](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN#diff-c3JjL2FyYml0cmFyeS9zdHJpbmdPZi50cw==) | `100.00% <100.00%> (ø)` | |
| ... and [18 more](https://codecov.io/gh/dubzzz/fast-check/pull/1802/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dubzzz/fast-check/pull/1802?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dubzzz/fast-check/pull/1802?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN). Last update [22b3216...01515d8](https://codecov.io/gh/dubzzz/fast-check/pull/1802?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Nicolas+DUBIEN).


Patch:
diff --git a/src/arbitrary/_internals/builders/Base64StringArbitraryBuilder.ts b/src/arbitrary/_internals/builders/Base64StringArbitraryBuilder.ts
new file mode 100644
index 00000000..333912dd
--- /dev/null
+++ b/src/arbitrary/_internals/builders/Base64StringArbitraryBuilder.ts
@@ -0,0 +1,43 @@
+import { Arbitrary } from '../../../check/arbitrary/definition/Arbitrary';
+import { base64 } from '../../base64';
+import { maxLengthFromMinLength } from '../helpers/MaxLengthFromMinLength';
+import { stringToBase64Mapper } from '../mappers/StringToBase64';
+import { buildStringArbitrary, StringFullConstraintsDefinition } from './StringArbitraryBuilder';
+
+/** @internal */
+function extractMinMaxConstraints(...args: StringFullConstraintsDefinition) {
+  if (args[0] !== undefined) {
+    if (typeof args[0] === 'number') {
+      if (typeof args[1] === 'number') {
+        // function(minLength, maxLength)
+        return { minLength: args[0], maxLength: args[1] };
+      } else {
+        // function(maxLength)
+        return { minLength: 0, maxLength: args[0] };
+      }
+    } else {
+      // function(constraints)
+      const minLength = args[0].minLength !== undefined ? args[0].minLength : 0;
+      const maxLength = args[0].maxLength !== undefined ? args[0].maxLength : maxLengthFromMinLength(minLength);
+      return { minLength, maxLength };
+    }
+  }
+  return { minLength: 0, maxLength: maxLengthFromMinLength(0) };
+}
+
+/** @internal */
+export function buildBase64StringArbitrary(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  const constraints = extractMinMaxConstraints(...args);
+  const unscaledMinLength = constraints.minLength;
+  const unscaledMaxLength = constraints.maxLength;
+
+  // base64 length is always a multiple of 4
+  const minLength = unscaledMinLength + 3 - ((unscaledMinLength + 3) % 4);
+  const maxLength = unscaledMaxLength - (unscaledMaxLength % 4);
+
+  if (minLength > maxLength) throw new Error('Minimal length should be inferior or equal to maximal length');
+  if (minLength % 4 !== 0) throw new Error('Minimal length of base64 strings must be a multiple of 4');
+  if (maxLength % 4 !== 0) throw new Error('Maximal length of base64 strings must be a multiple of 4');
+
+  return buildStringArbitrary(base64(), { minLength, maxLength }).map(stringToBase64Mapper);
+}
diff --git a/src/arbitrary/_internals/builders/StringArbitraryBuilder.ts b/src/arbitrary/_internals/builders/StringArbitraryBuilder.ts
new file mode 100644
index 00000000..11afa625
--- /dev/null
+++ b/src/arbitrary/_internals/builders/StringArbitraryBuilder.ts
@@ -0,0 +1,39 @@
+import { Arbitrary } from '../../../check/arbitrary/definition/Arbitrary';
+import { array } from '../../array';
+
+/**
+ * Constraints to be applied on arbitraries for strings
+ * @remarks Since 2.4.0
+ * @public
+ */
+export interface StringSharedConstraints {
+  /**
+   * Lower bound of the generated string length (included)
+   * @remarks Since 2.4.0
+   */
+  minLength?: number;
+  /**
+   * Upper bound of the generated string length (included)
+   * @remarks Since 2.4.0
+   */
+  maxLength?: number;
+}
+
+/** @internal */
+export type StringFullConstraintsDefinition = [] | [number] | [number, number] | [StringSharedConstraints];
+
+/** @internal */
+export function buildStringArbitrary(
+  charArb: Arbitrary<string>,
+  ...args: StringFullConstraintsDefinition
+): Arbitrary<string> {
+  const arrayArb =
+    args[0] !== undefined
+      ? typeof args[0] === 'number'
+        ? typeof args[1] === 'number'
+          ? array(charArb, { minLength: args[0], maxLength: args[1] })
+          : array(charArb, { maxLength: args[0] })
+        : array(charArb, args[0])
+      : array(charArb);
+  return arrayArb.map((tab) => tab.join(''));
+}
diff --git a/src/arbitrary/_internals/mappers/StringToBase64.ts b/src/arbitrary/_internals/mappers/StringToBase64.ts
new file mode 100644
index 00000000..da5f34f0
--- /dev/null
+++ b/src/arbitrary/_internals/mappers/StringToBase64.ts
@@ -0,0 +1,13 @@
+/** @internal */
+export function stringToBase64Mapper(s: string): string {
+  switch (s.length % 4) {
+    case 0:
+      return s;
+    case 3:
+      return `${s}=`;
+    case 2:
+      return `${s}==`;
+    default:
+      return s.slice(1); // remove one extra char to get to %4 == 0
+  }
+}
diff --git a/src/arbitrary/asciiString.ts b/src/arbitrary/asciiString.ts
new file mode 100644
index 00000000..d8b9a2a3
--- /dev/null
+++ b/src/arbitrary/asciiString.ts
@@ -0,0 +1,55 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { ascii } from './ascii';
+import {
+  buildStringArbitrary,
+  StringFullConstraintsDefinition,
+  StringSharedConstraints,
+} from './_internals/builders/StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For strings of {@link ascii}
+ * @remarks Since 0.0.1
+ * @public
+ */
+function asciiString(): Arbitrary<string>;
+/**
+ * For strings of {@link ascii}
+ *
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.asciiString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.1
+ * @public
+ */
+function asciiString(maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link ascii}
+ *
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.asciiString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function asciiString(minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link ascii}
+ *
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function asciiString(constraints: StringSharedConstraints): Arbitrary<string>;
+function asciiString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildStringArbitrary(ascii(), ...args);
+}
+export { asciiString };
diff --git a/src/arbitrary/base64String.ts b/src/arbitrary/base64String.ts
new file mode 100644
index 00000000..6c6a56f8
--- /dev/null
+++ b/src/arbitrary/base64String.ts
@@ -0,0 +1,60 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { StringSharedConstraints, StringFullConstraintsDefinition } from './_internals/builders/StringArbitraryBuilder';
+import { buildBase64StringArbitrary } from './_internals/builders/Base64StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For base64 strings
+ *
+ * A base64 string will always have a length multiple of 4 (padded with =)
+ *
+ * @remarks Since 0.0.1
+ * @public
+ */
+function base64String(): Arbitrary<string>;
+/**
+ * For base64 strings
+ *
+ * A base64 string will always have a length multiple of 4 (padded with =)
+ *
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.base64String({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.1
+ * @public
+ */
+function base64String(maxLength: number): Arbitrary<string>;
+/**
+ * For base64 strings
+ *
+ * A base64 string will always have a length multiple of 4 (padded with =)
+ *
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.base64String({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function base64String(minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For base64 strings
+ *
+ * A base64 string will always have a length multiple of 4 (padded with =)
+ *
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function base64String(constraints: StringSharedConstraints): Arbitrary<string>;
+function base64String(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildBase64StringArbitrary(...args);
+}
+export { base64String };
diff --git a/src/arbitrary/fullUnicodeString.ts b/src/arbitrary/fullUnicodeString.ts
new file mode 100644
index 00000000..94baa07b
--- /dev/null
+++ b/src/arbitrary/fullUnicodeString.ts
@@ -0,0 +1,55 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { fullUnicode } from './fullUnicode';
+import {
+  buildStringArbitrary,
+  StringFullConstraintsDefinition,
+  StringSharedConstraints,
+} from './_internals/builders/StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For strings of {@link fullUnicode}
+ * @remarks Since 0.0.11
+ * @public
+ */
+function fullUnicodeString(): Arbitrary<string>;
+/**
+ * For strings of {@link fullUnicode}
+ *
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.fullUnicodeString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function fullUnicodeString(maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link fullUnicode}
+ *
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.fullUnicodeString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function fullUnicodeString(minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link fullUnicode}
+ *
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function fullUnicodeString(constraints: StringSharedConstraints): Arbitrary<string>;
+function fullUnicodeString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildStringArbitrary(fullUnicode(), ...args);
+}
+export { fullUnicodeString };
diff --git a/src/arbitrary/hexaString.ts b/src/arbitrary/hexaString.ts
new file mode 100644
index 00000000..6a788855
--- /dev/null
+++ b/src/arbitrary/hexaString.ts
@@ -0,0 +1,55 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { hexa } from './hexa';
+import {
+  buildStringArbitrary,
+  StringFullConstraintsDefinition,
+  StringSharedConstraints,
+} from './_internals/builders/StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For strings of {@link hexa}
+ * @remarks Since 0.0.1
+ * @public
+ */
+function hexaString(): Arbitrary<string>;
+/**
+ * For strings of {@link hexa}
+ *
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.hexaString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.1
+ * @public
+ */
+function hexaString(maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link hexa}
+ *
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.hexaString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function hexaString(minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link hexa}
+ *
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function hexaString(constraints: StringSharedConstraints): Arbitrary<string>;
+function hexaString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildStringArbitrary(hexa(), ...args);
+}
+export { hexaString };
diff --git a/src/arbitrary/string.ts b/src/arbitrary/string.ts
new file mode 100644
index 00000000..242905d4
--- /dev/null
+++ b/src/arbitrary/string.ts
@@ -0,0 +1,55 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { char } from './char';
+import {
+  buildStringArbitrary,
+  StringFullConstraintsDefinition,
+  StringSharedConstraints,
+} from './_internals/builders/StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For strings of {@link char}
+ * @remarks Since 0.0.1
+ * @public
+ */
+function string(): Arbitrary<string>;
+/**
+ * For strings of {@link char}
+ *
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.string({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.1
+ * @public
+ */
+function string(maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link char}
+ *
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.string({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function string(minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link char}
+ *
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function string(constraints: StringSharedConstraints): Arbitrary<string>;
+function string(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildStringArbitrary(char(), ...args);
+}
+export { string };
diff --git a/src/arbitrary/string16bits.ts b/src/arbitrary/string16bits.ts
new file mode 100644
index 00000000..1878ed6e
--- /dev/null
+++ b/src/arbitrary/string16bits.ts
@@ -0,0 +1,55 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { char16bits } from './char16bits';
+import {
+  buildStringArbitrary,
+  StringFullConstraintsDefinition,
+  StringSharedConstraints,
+} from './_internals/builders/StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For strings of {@link char16bits}
+ * @remarks Since 0.0.11
+ * @public
+ */
+function string16bits(): Arbitrary<string>;
+/**
+ * For strings of {@link char16bits}
+ *
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.string16bits({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function string16bits(maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link char16bits}
+ *
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.string16bits({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function string16bits(minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link char16bits}
+ *
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function string16bits(constraints: StringSharedConstraints): Arbitrary<string>;
+function string16bits(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildStringArbitrary(char16bits(), ...args);
+}
+export { string16bits };
diff --git a/src/arbitrary/stringOf.ts b/src/arbitrary/stringOf.ts
new file mode 100644
index 00000000..5a2805ae
--- /dev/null
+++ b/src/arbitrary/stringOf.ts
@@ -0,0 +1,60 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import {
+  buildStringArbitrary,
+  StringFullConstraintsDefinition,
+  StringSharedConstraints,
+} from './_internals/builders/StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For strings using the characters produced by `charArb`
+ *
+ * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
+ *
+ * @remarks Since 1.1.3
+ * @public
+ */
+function stringOf(charArb: Arbitrary<string>): Arbitrary<string>;
+/**
+ * For strings using the characters produced by `charArb`
+ *
+ * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.stringOf(charArb, {maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 1.1.3
+ * @public
+ */
+function stringOf(charArb: Arbitrary<string>, maxLength: number): Arbitrary<string>;
+/**
+ * For strings using the characters produced by `charArb`
+ *
+ * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.stringOf(charArb, {minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 1.1.3
+ * @public
+ */
+function stringOf(charArb: Arbitrary<string>, minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For strings using the characters produced by `charArb`
+ *
+ * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function stringOf(charArb: Arbitrary<string>, constraints: StringSharedConstraints): Arbitrary<string>;
+function stringOf(charArb: Arbitrary<string>, ...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildStringArbitrary(charArb, ...args);
+}
+export { stringOf };
diff --git a/src/arbitrary/unicodeString.ts b/src/arbitrary/unicodeString.ts
new file mode 100644
index 00000000..97cdb8d1
--- /dev/null
+++ b/src/arbitrary/unicodeString.ts
@@ -0,0 +1,55 @@
+import { Arbitrary } from '../check/arbitrary/definition/Arbitrary';
+import { unicode } from './unicode';
+import {
+  buildStringArbitrary,
+  StringFullConstraintsDefinition,
+  StringSharedConstraints,
+} from './_internals/builders/StringArbitraryBuilder';
+export { StringSharedConstraints } from './_internals/builders/StringArbitraryBuilder';
+
+/**
+ * For strings of {@link unicode}
+ * @remarks Since 0.0.11
+ * @public
+ */
+function unicodeString(): Arbitrary<string>;
+/**
+ * For strings of {@link unicode}
+ *
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.unicodeString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function unicodeString(maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link unicode}
+ *
+ * @param minLength - Lower bound of the generated string length
+ * @param maxLength - Upper bound of the generated string length
+ *
+ * @deprecated
+ * Superceded by `fc.unicodeString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
+ * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
+ *
+ * @remarks Since 0.0.11
+ * @public
+ */
+function unicodeString(minLength: number, maxLength: number): Arbitrary<string>;
+/**
+ * For strings of {@link unicode}
+ *
+ * @param constraints - Constraints to apply when building instances
+ *
+ * @remarks Since 2.4.0
+ * @public
+ */
+function unicodeString(constraints: StringSharedConstraints): Arbitrary<string>;
+function unicodeString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
+  return buildStringArbitrary(unicode(), ...args);
+}
+export { unicodeString };
diff --git a/src/check/arbitrary/EmailArbitrary.ts b/src/check/arbitrary/EmailArbitrary.ts
index 990ecb5b..16944429 100644
--- a/src/check/arbitrary/EmailArbitrary.ts
+++ b/src/check/arbitrary/EmailArbitrary.ts
@@ -1,7 +1,7 @@
 import { array } from '../../arbitrary/array';
 import { buildLowerAlphaNumericArb } from './helpers/SpecificCharacterRange';
 import { domain } from './HostArbitrary';
-import { stringOf } from './StringArbitrary';
+import { stringOf } from '../../arbitrary/stringOf';
 import { tuple } from '../../arbitrary/tuple';
 import { Arbitrary } from './definition/Arbitrary';
 
diff --git a/src/check/arbitrary/HostArbitrary.ts b/src/check/arbitrary/HostArbitrary.ts
index 2e8c9a29..c4b589f6 100644
--- a/src/check/arbitrary/HostArbitrary.ts
+++ b/src/check/arbitrary/HostArbitrary.ts
@@ -5,7 +5,7 @@ import {
   buildLowerAlphaNumericArb,
 } from './helpers/SpecificCharacterRange';
 import { option } from '../../arbitrary/option';
-import { stringOf } from './StringArbitrary';
+import { stringOf } from '../../arbitrary/stringOf';
 import { tuple } from '../../arbitrary/tuple';
 import { Arbitrary } from './definition/Arbitrary';
 
diff --git a/src/check/arbitrary/IpArbitrary.ts b/src/check/arbitrary/IpArbitrary.ts
index 0a68ab3d..2c855eaa 100644
--- a/src/check/arbitrary/IpArbitrary.ts
+++ b/src/check/arbitrary/IpArbitrary.ts
@@ -3,7 +3,7 @@ import { constantFrom } from '../../arbitrary/constantFrom';
 import { Arbitrary } from './definition/Arbitrary';
 import { nat } from '../../arbitrary/nat';
 import { oneof } from '../../arbitrary/oneof';
-import { hexaString } from './StringArbitrary';
+import { hexaString } from '../../arbitrary/hexaString';
 import { tuple } from '../../arbitrary/tuple';
 
 /**
diff --git a/src/check/arbitrary/ObjectArbitrary.ts b/src/check/arbitrary/ObjectArbitrary.ts
index b186e4cf..5a3b7a1d 100644
--- a/src/check/arbitrary/ObjectArbitrary.ts
+++ b/src/check/arbitrary/ObjectArbitrary.ts
@@ -11,7 +11,8 @@ import { maxSafeInteger } from '../../arbitrary/maxSafeInteger';
 import { memo, Memo } from '../../arbitrary/memo';
 import { oneof } from '../../arbitrary/oneof';
 import { set } from '../../arbitrary/set';
-import { string, unicodeString } from './StringArbitrary';
+import { string } from '../../arbitrary/string';
+import { unicodeString } from '../../arbitrary/unicodeString';
 import { tuple } from '../../arbitrary/tuple';
 import { bigInt } from '../../arbitrary/bigInt';
 import { date } from './DateArbitrary';
diff --git a/src/check/arbitrary/StringArbitrary.ts b/src/check/arbitrary/StringArbitrary.ts
deleted file mode 100644
index c56e9983..00000000
--- a/src/check/arbitrary/StringArbitrary.ts
+++ /dev/null
@@ -1,469 +0,0 @@
-import { array } from '../../arbitrary/array';
-import { maxLengthFromMinLength } from '../../arbitrary/_internals/helpers/MaxLengthFromMinLength';
-import { ascii } from '../../arbitrary/ascii';
-import { base64 } from '../../arbitrary/base64';
-import { char } from '../../arbitrary/char';
-import { char16bits } from '../../arbitrary/char16bits';
-import { fullUnicode } from '../../arbitrary/fullUnicode';
-import { hexa } from '../../arbitrary/hexa';
-import { unicode } from '../../arbitrary/unicode';
-import { Arbitrary } from './definition/Arbitrary';
-
-/**
- * Constraints to be applied on arbitraries for strings
- * @remarks Since 2.4.0
- * @public
- */
-export interface StringSharedConstraints {
-  /**
-   * Lower bound of the generated string length (included)
-   * @remarks Since 2.4.0
-   */
-  minLength?: number;
-  /**
-   * Upper bound of the generated string length (included)
-   * @remarks Since 2.4.0
-   */
-  maxLength?: number;
-}
-
-/** @internal */
-type StringFullConstraintsDefinition = [] | [number] | [number, number] | [StringSharedConstraints];
-
-/** @internal */
-function StringArbitrary(charArb: Arbitrary<string>, ...args: StringFullConstraintsDefinition) {
-  const arrayArb =
-    args[0] !== undefined
-      ? typeof args[0] === 'number'
-        ? typeof args[1] === 'number'
-          ? array(charArb, { minLength: args[0], maxLength: args[1] })
-          : array(charArb, { maxLength: args[0] })
-        : array(charArb, args[0])
-      : array(charArb);
-  return arrayArb.map((tab) => tab.join(''));
-}
-
-/** @internal */
-function Base64StringArbitrary(unscaledMinLength: number, unscaledMaxLength: number) {
-  // base64 length is always a multiple of 4
-  const minLength = unscaledMinLength + 3 - ((unscaledMinLength + 3) % 4);
-  const maxLength = unscaledMaxLength - (unscaledMaxLength % 4);
-
-  if (minLength > maxLength) throw new Error('Minimal length should be inferior or equal to maximal length');
-  if (minLength % 4 !== 0) throw new Error('Minimal length of base64 strings must be a multiple of 4');
-  if (maxLength % 4 !== 0) throw new Error('Maximal length of base64 strings must be a multiple of 4');
-  return StringArbitrary(base64(), { minLength, maxLength }).map((s) => {
-    switch (s.length % 4) {
-      case 0:
-        return s;
-      case 3:
-        return `${s}=`;
-      case 2:
-        return `${s}==`;
-      default:
-        return s.slice(1); // remove one extra char to get to %4 == 0
-    }
-  });
-}
-
-/**
- * For strings using the characters produced by `charArb`
- *
- * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
- *
- * @remarks Since 1.1.3
- * @public
- */
-function stringOf(charArb: Arbitrary<string>): Arbitrary<string>;
-/**
- * For strings using the characters produced by `charArb`
- *
- * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.stringOf(charArb, {maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 1.1.3
- * @public
- */
-function stringOf(charArb: Arbitrary<string>, maxLength: number): Arbitrary<string>;
-/**
- * For strings using the characters produced by `charArb`
- *
- * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.stringOf(charArb, {minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 1.1.3
- * @public
- */
-function stringOf(charArb: Arbitrary<string>, minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For strings using the characters produced by `charArb`
- *
- * @param charArb - Arbitrary able to generate random strings (possibly multiple characters)
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function stringOf(charArb: Arbitrary<string>, constraints: StringSharedConstraints): Arbitrary<string>;
-function stringOf(charArb: Arbitrary<string>, ...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  return StringArbitrary(charArb, ...args);
-}
-
-/**
- * For strings of {@link char}
- * @remarks Since 0.0.1
- * @public
- */
-function string(): Arbitrary<string>;
-/**
- * For strings of {@link char}
- *
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.string({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.1
- * @public
- */
-function string(maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link char}
- *
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.string({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function string(minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link char}
- *
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function string(constraints: StringSharedConstraints): Arbitrary<string>;
-function string(...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  return StringArbitrary(char(), ...args);
-}
-
-/**
- * For strings of {@link ascii}
- * @remarks Since 0.0.1
- * @public
- */
-function asciiString(): Arbitrary<string>;
-/**
- * For strings of {@link ascii}
- *
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.asciiString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.1
- * @public
- */
-function asciiString(maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link ascii}
- *
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.asciiString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function asciiString(minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link ascii}
- *
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function asciiString(constraints: StringSharedConstraints): Arbitrary<string>;
-function asciiString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  return StringArbitrary(ascii(), ...args);
-}
-
-/**
- * For strings of {@link char16bits}
- * @remarks Since 0.0.11
- * @public
- */
-function string16bits(): Arbitrary<string>;
-/**
- * For strings of {@link char16bits}
- *
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.string16bits({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function string16bits(maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link char16bits}
- *
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.string16bits({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function string16bits(minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link char16bits}
- *
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function string16bits(constraints: StringSharedConstraints): Arbitrary<string>;
-function string16bits(...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  return StringArbitrary(char16bits(), ...args);
-}
-
-/**
- * For strings of {@link unicode}
- * @remarks Since 0.0.11
- * @public
- */
-function unicodeString(): Arbitrary<string>;
-/**
- * For strings of {@link unicode}
- *
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.unicodeString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function unicodeString(maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link unicode}
- *
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.unicodeString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function unicodeString(minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link unicode}
- *
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function unicodeString(constraints: StringSharedConstraints): Arbitrary<string>;
-function unicodeString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  return StringArbitrary(unicode(), ...args);
-}
-
-/**
- * For strings of {@link fullUnicode}
- * @remarks Since 0.0.11
- * @public
- */
-function fullUnicodeString(): Arbitrary<string>;
-/**
- * For strings of {@link fullUnicode}
- *
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.fullUnicodeString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function fullUnicodeString(maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link fullUnicode}
- *
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.fullUnicodeString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function fullUnicodeString(minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link fullUnicode}
- *
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function fullUnicodeString(constraints: StringSharedConstraints): Arbitrary<string>;
-function fullUnicodeString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  return StringArbitrary(fullUnicode(), ...args);
-}
-
-/**
- * For strings of {@link hexa}
- * @remarks Since 0.0.1
- * @public
- */
-function hexaString(): Arbitrary<string>;
-/**
- * For strings of {@link hexa}
- *
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.hexaString({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.1
- * @public
- */
-function hexaString(maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link hexa}
- *
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.hexaString({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function hexaString(minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For strings of {@link hexa}
- *
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function hexaString(constraints: StringSharedConstraints): Arbitrary<string>;
-function hexaString(...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  return StringArbitrary(hexa(), ...args);
-}
-
-/**
- * For base64 strings
- *
- * A base64 string will always have a length multiple of 4 (padded with =)
- *
- * @remarks Since 0.0.1
- * @public
- */
-function base64String(): Arbitrary<string>;
-/**
- * For base64 strings
- *
- * A base64 string will always have a length multiple of 4 (padded with =)
- *
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.base64String({maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.1
- * @public
- */
-function base64String(maxLength: number): Arbitrary<string>;
-/**
- * For base64 strings
- *
- * A base64 string will always have a length multiple of 4 (padded with =)
- *
- * @param minLength - Lower bound of the generated string length
- * @param maxLength - Upper bound of the generated string length
- *
- * @deprecated
- * Superceded by `fc.base64String({minLength, maxLength})` - see {@link https://github.com/dubzzz/fast-check/issues/992 | #992}.
- * Ease the migration with {@link https://github.com/dubzzz/fast-check/tree/main/codemods/unify-signatures | our codemod script}.
- *
- * @remarks Since 0.0.11
- * @public
- */
-function base64String(minLength: number, maxLength: number): Arbitrary<string>;
-/**
- * For base64 strings
- *
- * A base64 string will always have a length multiple of 4 (padded with =)
- *
- * @param constraints - Constraints to apply when building instances
- *
- * @remarks Since 2.4.0
- * @public
- */
-function base64String(constraints: StringSharedConstraints): Arbitrary<string>;
-function base64String(...args: StringFullConstraintsDefinition): Arbitrary<string> {
-  if (args[0] !== undefined) {
-    if (typeof args[0] === 'number') {
-      if (typeof args[1] === 'number') {
-        // base64String(arb, minLength, maxLength)
-        return Base64StringArbitrary(args[0], args[1]);
-      } else {
-        // base64String(arb, maxLength)
-        return Base64StringArbitrary(0, args[0]);
-      }
-    } else {
-      // base64String(arb, constraints)
-      const minLength = args[0].minLength !== undefined ? args[0].minLength : 0;
-      const maxLength = args[0].maxLength !== undefined ? args[0].maxLength : maxLengthFromMinLength(minLength);
-      return Base64StringArbitrary(minLength, maxLength);
-    }
-  }
-  // base64String(arb)
-  return Base64StringArbitrary(0, maxLengthFromMinLength(0));
-}
-
-export { stringOf, string, asciiString, string16bits, unicodeString, fullUnicodeString, hexaString, base64String };
diff --git a/src/check/arbitrary/WebArbitrary.ts b/src/check/arbitrary/WebArbitrary.ts
index e604c935..b948276a 100644
--- a/src/check/arbitrary/WebArbitrary.ts
+++ b/src/check/arbitrary/WebArbitrary.ts
@@ -7,7 +7,7 @@ import { nat } from '../../arbitrary/nat';
 import { ipV4, ipV4Extended, ipV6 } from './IpArbitrary';
 import { oneof } from '../../arbitrary/oneof';
 import { option } from '../../arbitrary/option';
-import { stringOf } from './StringArbitrary';
+import { stringOf } from '../../arbitrary/stringOf';
 import { tuple } from '../../arbitrary/tuple';
 import { Arbitrary } from './definition/Arbitrary';
 
diff --git a/src/fast-check-default.ts b/src/fast-check-default.ts
index ed657afd..0915fae5 100644
--- a/src/fast-check-default.ts
+++ b/src/fast-check-default.ts
@@ -73,17 +73,14 @@ import { option, OptionConstraints } from './arbitrary/option';
 import { record, RecordConstraints, RecordValue } from './check/arbitrary/RecordArbitrary';
 import { set, SetConstraints } from './arbitrary/set';
 import { infiniteStream } from './arbitrary/infiniteStream';
-import {
-  asciiString,
-  base64String,
-  fullUnicodeString,
-  hexaString,
-  string,
-  string16bits,
-  stringOf,
-  StringSharedConstraints,
-  unicodeString,
-} from './check/arbitrary/StringArbitrary';
+import { asciiString } from './arbitrary/asciiString';
+import { base64String } from './arbitrary/base64String';
+import { fullUnicodeString } from './arbitrary/fullUnicodeString';
+import { hexaString } from './arbitrary/hexaString';
+import { string, StringSharedConstraints } from './arbitrary/string';
+import { string16bits } from './arbitrary/string16bits';
+import { stringOf } from './arbitrary/stringOf';
+import { unicodeString } from './arbitrary/unicodeString';
 import { shuffledSubarray, subarray, SubarrayConstraints } from './check/arbitrary/SubarrayArbitrary';
 import { genericTuple } from './arbitrary/genericTuple';
 import { tuple } from './arbitrary/tuple';


Test patch:
diff --git a/test/unit/arbitrary/MixedCaseArbitrary.itest.spec.ts b/test/unit/arbitrary/MixedCaseArbitrary.itest.spec.ts
index 596a5ab0..06ed369b 100644
--- a/test/unit/arbitrary/MixedCaseArbitrary.itest.spec.ts
+++ b/test/unit/arbitrary/MixedCaseArbitrary.itest.spec.ts
@@ -1,5 +1,5 @@
 import { nat } from '../../../src/arbitrary/nat';
-import { stringOf } from '../../../src/check/arbitrary/StringArbitrary';
+import { stringOf } from '../../../src/arbitrary/stringOf';
 import { mixedCase } from '../../../src/arbitrary/mixedCase';
 
 import * as genericHelper from '../check/arbitrary/generic/GenericArbitraryHelper';
diff --git a/test/unit/check/arbitrary/StringArbitrary.spec.ts b/test/unit/arbitrary/StringArbitrary.spec.ts
similarity index 94%
rename from test/unit/check/arbitrary/StringArbitrary.spec.ts
rename to test/unit/arbitrary/StringArbitrary.spec.ts
index c0a4acfb..ecc292aa 100644
--- a/test/unit/check/arbitrary/StringArbitrary.spec.ts
+++ b/test/unit/arbitrary/StringArbitrary.spec.ts
@@ -1,20 +1,18 @@
-import * as fc from '../../../../lib/fast-check';
+import * as fc from '../../../lib/fast-check';
 
-import { constantFrom } from '../../../../src/arbitrary/constantFrom';
-import {
-  asciiString,
-  base64String,
-  hexaString,
-  string,
-  string16bits,
-  stringOf,
-  unicodeString,
-} from '../../../../src/check/arbitrary/StringArbitrary';
+import { constantFrom } from '../../../src/arbitrary/constantFrom';
+import { asciiString } from '../../../src/arbitrary/asciiString';
+import { base64String } from '../../../src/arbitrary/base64String';
+import { hexaString } from '../../../src/arbitrary/hexaString';
+import { string } from '../../../src/arbitrary/string';
+import { string16bits } from '../../../src/arbitrary/string16bits';
+import { stringOf } from '../../../src/arbitrary/stringOf';
+import { unicodeString } from '../../../src/arbitrary/unicodeString';
 
-import { generateOneValue } from './generic/GenerateOneValue';
-import * as genericHelper from './generic/GenericArbitraryHelper';
+import { generateOneValue } from '../check/arbitrary/generic/GenerateOneValue';
+import * as genericHelper from '../check/arbitrary/generic/GenericArbitraryHelper';
 
-import * as stubRng from '../../stubs/generators';
+import * as stubRng from '../stubs/generators';
 
 const minMax = fc
   .tuple(fc.integer(0, 10000), fc.integer(0, 10000))
diff --git a/test/unit/check/arbitrary/SetArbitrary.spec.ts b/test/unit/check/arbitrary/SetArbitrary.spec.ts
index 0e6e8814..75f9da6a 100644
--- a/test/unit/check/arbitrary/SetArbitrary.spec.ts
+++ b/test/unit/check/arbitrary/SetArbitrary.spec.ts
@@ -2,7 +2,7 @@ import * as fc from '../../../../lib/fast-check';
 
 import { set } from '../../../../src/arbitrary/set';
 import { nat } from '../../../../src/arbitrary/nat';
-import { string } from '../../../../src/check/arbitrary/StringArbitrary';
+import { string } from '../../../../src/arbitrary/string';
 
 import { generateOneValue } from './generic/GenerateOneValue';
 import * as genericHelper from './generic/GenericArbitraryHelper';