Annual report pursuant to Section 13 and 15(d)

Stockholders' Equity (Deficit) - Additional Information (Details)

v3.19.1
Stockholders' Equity (Deficit) - Additional Information (Details)
$ / shares in Units, $ in Thousands
1 Months Ended 3 Months Ended 12 Months Ended
Oct. 01, 2018
shares
Sep. 14, 2018
Jul. 31, 2018
$ / shares
shares
Aug. 31, 2017
$ / shares
shares
Jul. 31, 2018
USD ($)
$ / shares
shares
Dec. 31, 2018
USD ($)
$ / shares
shares
Dec. 31, 2017
USD ($)
$ / shares
shares
Dec. 31, 2016
USD ($)
shares
Oct. 30, 2018
$ / shares
shares
Dec. 31, 2015
shares
Temporary Equity [Line Items]                    
Funding through sale of stock | $           $ 84,739 $ 0 $ 0    
Voting rights per share           one vote per share        
Preferred Stock, Shares Authorized           10,000,000 0   10,000,000  
Preferred Stock, Par value | $ / shares           $ 0.001 $ 0.001   $ 0.001  
Preferred Stock, Shares Outstanding           0 0      
Common Stock                    
Temporary Equity [Line Items]                    
Stock split conversion ratio   36.3                
Series E Redeemable Convertible Preferred Stock                    
Temporary Equity [Line Items]                    
Funding through sale of stock | $         $ 85,400          
Sale and issuance of shares     319,305,718   319,305,718          
Redeemable convertible preferred stock, par value | $ / shares     $ 0.2674   $ 0.2674          
Stock split conversion ratio     0.8374     36.3636        
Preferred stock, conversion basis           1-for-0.0275        
Series E Redeemable Convertible Preferred Stock | Oxford Finance LLC and Silicon Valley Bank | Loan and Security Agreement                    
Temporary Equity [Line Items]                    
Issuance of warrants to purchase shares       1,682,871            
Exercise price per share | $ / shares       $ 0.2674            
Term of warrant exercisable       10 years            
Series D-2 Redeemable Convertible Preferred Stock | Oxford Finance LLC and Silicon Valley Bank | Loan and Security Agreement                    
Temporary Equity [Line Items]                    
Issuance of warrants to purchase shares       682,230            
Exercise price per share | $ / shares       $ 0.6596            
Series C Preferred Stock                    
Temporary Equity [Line Items]                    
Stock split conversion ratio           27.0270        
Preferred stock, conversion basis           1-for-0.0370        
Cancellation of redeemable convertible preferred warrants 1,232,220                  
Conversion of warrants to purchase of shares of common stock 687,928                  
Redeemable Convertible Preferred Stock                    
Temporary Equity [Line Items]                    
Sale and issuance of shares           0 173,750,421      
Redeemable convertible preferred stock, par value | $ / shares           $ 0.001 $ 0.001      
Redeemable convertible preferred stock, shares outstanding           0 173,750,421 173,750,421   173,750,421
Redeemable Convertible Preferred Stock | Initial Public Offering                    
Temporary Equity [Line Items]                    
Redeemable convertible preferred stock, shares outstanding 0                  
Redeemable Convertible Preferred Stock | Common Stock | Initial Public Offering                    
Temporary Equity [Line Items]                    
Convertible preferred stock converted into common stock 16,028,462                  
Redeemable Convertible Preferred Stock | Warrants | Initial Public Offering                    
Temporary Equity [Line Items]                    
Convertible preferred stock converted into common stock 71,813