SAN FRANCISCO — For years, a divisive debate has raged in the United States over the health consequences of nicotine e-cigarettes. During the same time, vaping of a more contentious substance has been swiftly growing, with scant notice from public health officials.

Millions of people now inhale marijuana not from joints or pipes filled with burning leaves but through sleek devices and cartridges filled with flavored cannabis oils. People in the legalized marijuana industry say vaping products now account for 30 percent or more of their business . Teenagers, millennials and baby boomers alike have been drawn to the technology — no ash, a faint smell, easy to hide — and the potentially dangerous consequences are only now becoming evident.

Most of the patients in the outbreak of severe lung illnesses linked to vaping — which has left 1,479 people sick and 33 dead so far — vaped THC, the ingredient in marijuana that makes people high. Until more information is known, officials at the Centers for Disease Control and Prevention have warned people not to vape cannabis products.

To some scientists, and even industry leaders, warning signs have been apparent for years as vaping cannabis grew in the shadows, propelled by a patchwork of regulations, a wave of state-by-state legalization and a soaring supply of low-cost marijuana.