string };
                  
                  
                  type To = { id: string };
                  
                  
                  
                  
                  
                  const mapper = (a: From): To => {
                  
                  
                    return ObjectBuilder.new<To>()
                  
                  
                      .with('id', a.id)
                  
                  
                      .build();
                  
                  
                  };
                  
                  
                  
                  
                  
                  mapper({}).id.toLowerCase()
                  
                  
                  
                  
                  
                  
                  
                  
                  typescript не ругнется здесь
                  
                  
                
https://github.com/microsoft/TypeScript/issues/43817#issuecomment-827746462
Обсуждают сегодня