The DNA sequence to replicate
Optional configuration for replication
ValidationResult containing the two replicated DNA strands
import { DNA, replicateDNA } from 'ts-dna';
const dna = new DNA('ATGCGATCGTAGCTACGT');
const result = replicateDNA(dna);
if (result.success) {
const [strand1, strand2] = result.data.replicatedStrands;
console.log('Replication completed!');
console.log('Steps taken:', result.data.steps);
}
// With custom organism and options
import { HUMAN } from 'ts-dna';
const result = replicateDNA(dna, {
organism: HUMAN,
enableDetailedLogging: true
});
Replicates a DNA sequence, producing two identical copies.
This is the main entry point for DNA replication in ts-dna. It handles all the biological complexity of DNA replication including: