Function isDNA

  • Type guard for checking if a nucleic acid is DNA

    Parameters

    Returns nucleicAcid is DNA

    True if the nucleic acid is DNA, false otherwise

    Example

     //pass a DNA object
    isDNA(new DNA()); //returns true

    //pass an RNA object
    isDNA(new RNA()); //returns false