팩토리 패턴상속 관계에 있는 두 클래스에서 상위 클래스가 중요한 뼈대를 결정하고, 하위클래스는 객체 생성에 대한 구체적인 내용을 결정하는 패턴상위 클래스에서 객체 생성방식에 대해 관여하지 않아 유연성이 높음객체 생성 방식은 하위 클래스에서 관리하므로 유지보수가 용이함예시class Factory { // 상위 클래스 static createClass(type) { const factory = factoryList[type] return factory.createClass() // 하위 클래스 로직에 관계없음 }}class Lower1 { constructor() { this.name = "lower1" }}class Lower2 { con..