2021 required CSS architecture system (video source code Qi) online disk learning
2021 required CSS architecture system
The contents learned in Chapter 2 are: vue3 creation and initial configuration, vue3 creation and initial configuration, tips for node version selection, vx (cmL46679910) CSS design pattern completion (1)
public class OptimizeException { @Data public static class CustomException extends RuntimeException { private String key; private String message; public CustomException(String key, String message) { super(String.format("(%s)-[%s]", key , message)); this.key = key; this.message = message; } @Override public Throwable fillInStackTrace() { return this; } @Override public String toString() { return String.format("(%s)-[%s]", key , message); } } private static void fun(String name) { if (!"qinyi".equals(name)) { throw new CustomException("OptimizeException.fun.35", "name is not qinyi..."); } } public static void main(String[] args) { fun("imooc-qinyi"); } }
CSS design pattern completion (2), (video resource vx (cmL46679910)) CSS design pattern completion (3), rewrite the following styles according to OOCSS principles, CSS architecture scheme, Settings layer code implementation of CSS architecture, Tools layer code implementation of CSS architecture (I), Tools layer code implementation of CSS architecture (II), base layer code implementation of CSS architecture (1) Base layer code implementation of CSS architecture (2), Components layer code implementation of CSS architecture (I)
public class DebugVariable { @Data @NoArgsConstructor @AllArgsConstructor private static class Imoocer { private String name; private int age; private double salary; } private static boolean isRobotImoocer(Imoocer imoocer) { return imoocer.getName().endsWith("robot"); } private static Map<String, String> objToMap(Imoocer imoocer) { System.out.println("coming in objToMap......"); Map<String, String> result = new HashMap<>(); boolean isRobot = isRobotImoocer(imoocer); if (isRobot) { throw new RuntimeException("imoocer is robot"); } if (StrUtil.isEmpty(imoocer.getName())) { imoocer.setName("imooc-qinyi"); } result.put("name", imoocer.getName()); result.put("age", String.valueOf(imoocer.getAge())); result.put("salary", String.valueOf(imoocer.getSalary())); return result; } public static void main(String[] args) { Imoocer imoocer = new Imoocer("qinyi", 19, 0.0); System.out.println(objToMap(imoocer)); } }
Components layer code implementation of CSS architecture (middle), components layer code implementation of CSS architecture (lower), Acss layer code implementation of CSS architecture (upper) (video resource vx (cml4667910)), Acss layer code implementation of CSS architecture (lower), Theme layer code implementation of CSS architecture (upper), Theme layer code implementation of CSS architecture (middle) The Theme layer code implementation of CSS architecture (Part 2).
The contents of Chapter 3 are: building local MockJs (top), building local MockJs (bottom), responsive layout (top), responsive layout (bottom), home page design idea, Elements layer extension of architecture, ACSS layer extension of Architecture (top), ACSS layer extension of Architecture (bottom)
@SuppressWarnings("all") public class LogbackHolder { /** * <h2>Get logger instance by name</h2> * */ public static Logger getLogger(String name) { LoggerContext loggerContext = (LoggerContext) LoggerFactory.getILoggerFactory(); // If the logger is not created if (loggerContext.exists(name) == null) { // Dynamically construct the logger object yourself return buildLogger(name); } return loggerContext.getLogger(name); } /** * <h2>Dynamically construct logger instances</h2> * */ private static Logger buildLogger(String name) { LoggerContext loggerContext = (LoggerContext) LoggerFactory.getILoggerFactory(); Logger logger = loggerContext.getLogger(name); // Configure rollingFileAppender RollingFileAppender rollingFileAppender = new RollingFileAppender(); rollingFileAppender.setName(name); rollingFileAppender.setContext(loggerContext); // Configure rollingPolicy TimeBasedRollingPolicy rollingPolicy = new TimeBasedRollingPolicy(); rollingPolicy.setFileNamePattern("/tmp/log/" + name + ".%d{yyyyMM}.log"); rollingPolicy.setParent(rollingFileAppender); rollingPolicy.setContext(loggerContext); rollingPolicy.start(); // Configure encoder PatternLayoutEncoder encoder = new PatternLayoutEncoder(); encoder.setCharset(StandardCharsets.UTF_8); encoder.setPattern("%msg%n"); encoder.setContext(loggerContext); encoder.start(); rollingFileAppender.setRollingPolicy(rollingPolicy); rollingFileAppender.setEncoder(encoder); rollingFileAppender.start(); // Configure logger logger.addAppender(rollingFileAppender); logger.setAdditive(false); logger.setLevel(Level.INFO); return logger; } public static void main(String[] args) { getLogger("qinyi").info("imooc qinyi use logback..."); } }
. the Components layer extension of the architecture (top), the Components layer extension of the architecture (bottom), (video resource vx (cmL46679910)) multi-color icon SvgIcon, the star icon in the launch component is implemented with SvgIcon, the rotation diagram is implemented with pure CSS, the home page layout is completed (top), and the home page layout is completed (bottom).
The contents of Chapter 4 are: the conception of the design draft of the mall page, the extension of the Components layer of the architecture, and the completion of the mall page layout.
The contents of Chapter 5 are:
public class OtherPrinciples { /** * <h2>Capture the necessary code segments, and do not use large segments</h2> * */ public static long suitableTryCatch(String start, String end) { LocalDate startDay; LocalDate endDay; try { startDay = LocalDate.from(DateTimeFormatter.ofPattern("yyyy-MM-dd") .parse(start)); endDay = LocalDate.from(DateTimeFormatter.ofPattern("yyyy-MM-dd") .parse(end)); } catch (DateTimeException ex) { ex.printStackTrace(); return -1; } return startDay.until(endDay, ChronoUnit.DAYS); } /** * <h2>Try not to catch exceptions, but more specific exceptions</h2> * */ public static void classifyException(String fileName) { try { FileInputStream file = new FileInputStream(fileName); int x = (byte) file.read(); } catch (IOException ex) { ex.printStackTrace(); } } /** * <h2>After exception handling, it shall be cleaned up in time to release resources</h2> * */ public static void closeResource(String fileName) { FileInputStream file = null; try { file = new FileInputStream(fileName); int x = (byte) file.read(); } catch (IOException ex) { ex.printStackTrace(); } finally { try { if (null != file) { file.close(); } } catch (IOException ex) { ex.printStackTrace(); } } } /** * <h2>Let abnormalities be exposed as soon as possible</h2> * */ public static void earlyException(String input) { // Detailed judgment if (null != input && !"".equals(input) && input.contains("qinyi")) { // .... } else { throw new IllegalArgumentException("error input: " + input); } // do something } }
Design concept of limited time quick grab page, Chinese font compression: font spider, border radius principle and Realization of complex graphics, completion of limited time quick grab page layout (top), completion of limited time quick grab page layout (middle) (video resource vx (cml4667910)), completion of limited time quick grab page layout (bottom).
The contents learned in Chapter 6 are: conception of design draft of live list page, expansion of filter effects on ACSS layer, completion of live list page layout (top), and completion of live list page layout (bottom).
The contents of Chapter 7 are: design idea of live broadcast detail page, selection of scheme and complete live broadcast detail page.