% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/has_pattern.R
\name{has_pattern}
\alias{has_pattern}
\title{Indicates if a string has a given pattern.}
\usage{
has_pattern(x, pattern)
}
\value{
Logical. `TRUE` indicates the string has a given pattern, `FALSE` otherwise.
}
\description{
Indicates if a string has a given pattern.
}
\examples{
library(stringi)

text <- dplyr::as_tibble(c('A designer knows that he has achieved perfection',
'not when there is nothing left to add',
'but when there is nothing left to take away.'))
has_pattern(text, 'nothing')
apply(text, 1, has_pattern, 'nothing')

}
