diff --git a/articles/2024/nocobase.md b/articles/2024/nocobase.md index fcc22bb..0901c85 100644 --- a/articles/2024/nocobase.md +++ b/articles/2024/nocobase.md @@ -6,6 +6,21 @@ yarn nocobase install yarn dev ``` -## 依赖 +## 模块 -- [umi可插拔的企业级 react 应用框架](https://umijs.org/) \ No newline at end of file +- [umi可插拔的企业级 react 应用框架](https://umijs.org/) + +### core +核心 + +#### create-nocobase-app +调用umi生成对应的有配置的内容 + +#### devtools +调用umi生成对应的有配置的内容 + + +### plugins +插件 +### presets +预设 \ No newline at end of file diff --git a/articles/demo.md b/articles/demo.md index e591577..26f60b0 100644 --- a/articles/demo.md +++ b/articles/demo.md @@ -149,6 +149,8 @@ $\lVert \boldsymbol{X}_i - \boldsymbol{S}_j \rVert^2$ $$ f(x,y,z) = 3y^2z \left( 3+\frac{7x+5}{1+y^2} \right) $$ + +$$ \frac{ {\rm d} u} { {\rm d} x} | _{x=0} $$ 分数 diff --git a/cg/ct.md b/cg/ct.md index a798508..2227800 100644 --- a/cg/ct.md +++ b/cg/ct.md @@ -70,6 +70,9 @@ WADO:Web Access to DICOM Objects - [itk-wasm document](https://wasm.itk.org/en/latest/typescript/distribution/vite.html) - [医疗业务学习笔记--DICOM协议的基础内容](https://zhuanlan.zhihu.com/p/74966427) - [一些资源与解析库A curated list of awesome DICOM resources and libraries.](https://github.com/open-dicom/awesome-dicom) +- [Orthanc 是一个开源的、基于 WEB 的 DICOM 服务器软件,它允许用户通过 DICOM Server、Web Server 和 RESTful API 方式进行访问。Orthanc 支持跨平台运行,包括 Windows 和 Linux 版本。](https://github.com/jodogne/OrthancContributed) + - [Conversion of non-standard DICOM files to DICOM P10 compliant files:](https://discourse.orthanc-server.org/t/conversion-of-non-standard-dicom-files-to-dicom-p10-compliant-files/365) + ## [NII](https://nifti.nimh.nih.gov/pub/dist/doc/ANALYZE75.pdf) diff --git a/cg/mesh/NURBS.md b/cg/mesh/NURBS.md index 9dee2af..41c49dc 100644 --- a/cg/mesh/NURBS.md +++ b/cg/mesh/NURBS.md @@ -1,5 +1,6 @@ # NURBS > +非均匀有理B样条, 这是一种数学表示3D几何的方法,能够准确描述从简单的2D线、圆、弧或曲线到非常复杂的3D自由曲面或实体的任何形状。如今,NURBS已成为CAD和计算机图形学的国际标准。 ## [The Nurbs Book]() > @@ -9,3 +10,17 @@ - [A small C++ library containing some NURBS-based geometric modeling algorithms and features I've been working on since 2013.](https://gitlab.com/ssv/Mobius) - [LNLib is a C++ NURBS Algorithms Library. These algorithms are primary referenced from The NURBS Book 2nd Edition. ](https://github.com/BIMCoderLiang/LNLib) - [LNLibViewer is a 3d viewer matches C++ NURBS algorithm library LNLib](https://github.com/BIMCoderLiang/LNLibViewer) + +### [Ken Versprille, the Inventor of NURBS, Tells about Past, Present, and Future of CAD 2013-5-30]() + +- CAD的3D互操作性、性能和公差管理是3D建模中最重要的挑战 +- 精度,当3D模型上的几何计算结果的精度低于模型下游算法所需的精度时,精度就成为一个主要问题。在3D建模软件的核心,容错建模方法非常重要。 +- 一些建模软件将交点定义为3D空间中的三维曲线,其他则定义为两个表面参数空间中的二维曲线。 +- 面面相交算法运行的速度通常是建模软件整体性能的根本。由于当今最流行的CAD应用程序是基于历史的,这些计算不断地被重新执行。 +- 使用参数空间曲线来存储交点曲线。至少可以很容易地使用2D参数曲线在3D曲线上生成采样点,这在另一种表示中是不可能的。 +- 工程软件强烈依赖于NURBS,而艺术3D建模产品则利用细分曲面,Autodesk的T-splines,它结合了NURBS和细分曲面的特点 +- 点云非常有趣,因为这个领域在CAD中正在迅速增长。我们可能会回顾计算机图形学的历史来考虑这个问题。计算机图形学最初是CAD的一部分,但随后它作为自己的技术发展得更快,计算机图形学市场变得比CAD市场大得多。现在计算机图形学开始回归,与CAD建立越来越多的联系。在某种意义上,点云技术也可能会发生类似的情况。 +- NURBS是一个理想的数学概念,它从贝塞尔曲线和曲面继承了显著的几何属性。然而,在当今的CAD中,NURBS主要用于内部表示曲线和曲面,而设计师和工程师通常处理的是挤出、旋转、扫掠、混合等概念。 +- 商业工程软件的开发人员完全意识到他们的客户是工程师,而不是数学家。工程师用我们称之为“特征”的术语来谈论他们的设计,例如扫掠、开洞等。 +- 实现更好互操作性的主要挑战既是技术挑战,也是商业挑战。有些情况下,软件供应商故意使他们的产品数据与竞争产品的数据交换变得困难。克服这一点需要时间和来自客户的压力。我已经提到了许多影响互操作性的技术问题,比如精度和隐藏的数据格式问题。一个额外的挑战是,大多数CAD产品是“移动目标”,它们不断被增强和改变,这影响了它们的数据结构。一个今天完美的互操作性解决方案很快就会过时。 +- 软件和电子技术的发展速度更快。如今,系统工程师是最受欢迎的职业。这里的系统意味着对机械、电气和软件三个方面的知识都有所了解。 diff --git a/cpl/cplusplus.md b/cpl/cplusplus.md index b72324f..dd8e7be 100644 --- a/cpl/cplusplus.md +++ b/cpl/cplusplus.md @@ -3,6 +3,7 @@ - [C++ Core Guidelines](http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines) - [The C++ Core Guidelines are a collaborative effort led by Bjarne Stroustrup, much like the C++ language itself. They are the result of many person-years of discussion and design across a number of organizations.](https://github.com/isocpp/CppCoreGuidelines) - [The Guidelines Support Library (GSL) contains functions and types that are suggested for use by the C++ Core Guidelines maintained by the Standard C++ Foundation. This repo contains Microsoft's implementation of GSL.](https://github.com/Microsoft/GSL) +- [What's In a Class? - The Interface Principle, This article appeared in C++ Report, 10(3), March 1998.](http://www.gotw.ca/publications/mill02.htm) ## 语言特性 @@ -284,6 +285,8 @@ base + sizeof * 偏移量,数组指针好像就是这样的,用*(a+b)访 - [Calling conventions for different C++ compilers and operating systems](https://www.agner.org/optimize/calling_conventions.pdf),更新到2023年的技术 - [微软出品C++下一代的多态Proxy: Next Generation Polymorphism in C++](https://github.com/microsoft/proxy) - [反射库refl-cpp is a header-only library which provides compile-time reflection and introspection capabilities to C++](https://github.com/veselink1/refl-cpp) +- [Google 开源了其内部多年使用的 C++ 代码库](https://github.com/abseil/abseil-cpp) +- [folly库 An open-source C++ library developed and used at Facebook. ](https://github.com/facebook/folly) ### 工具 diff --git a/web/index.md b/web/index.md index 5e7ef3f..5bb583b 100644 --- a/web/index.md +++ b/web/index.md @@ -1,5 +1,6 @@ # Web +- [nginx](/web/nginx/nginx.md) - [使用过的库](/web/library.md) - [正则表达式](/cpl/js/regularExpressions.js) - [webassembly](/web/webAssembly.md) @@ -21,13 +22,13 @@ - [适配屏幕](/web/adapt.screen.md) - [font](/web/font.md) - [http](/web/http.md) -- [nginx](/web/nginx.md) - [javascript](/cpl/web/ECMAScript.md) - [Web Check网站分析,分析各种配置,可参考网站的配置](https://web-check.as93.net/) - [Draggable objects可拖动的对象网页实现](https://www.redblobgames.com/making-of/draggable/) +- [CanIUse网站查看接口的普及率](https://caniuse.com/) ## WebGL @@ -39,8 +40,13 @@ - [笔记](/cg/babylonjs/index.md) + ## library +### [Browserslist](https://github.com/browserslist/browserslist) +对一些工具起作用的 使用[Can I Use data](https://caniuse.com/)数据来判断 +- [A smaller version of caniuse-db, with only the essentials! ](https://github.com/browserslist/caniuse-lite) + ### 多语言 > i18n是国际化的英文为 internationalization,为了方便,通常会简写为 i18n(开头的 i、中间的 18 个字符、末尾的 n) diff --git a/web/library.md b/web/library.md index 0475cb2..8f9c93d 100644 --- a/web/library.md +++ b/web/library.md @@ -1,7 +1,11 @@ -# Quill +# 库 + +相关库,工作中使用过 + +## Quill > quill富文本编辑器 -## dev +### dev 安装sharp npm config get userconfig 获取配置信息 @@ -9,7 +13,7 @@ npm config edit 打开默认的配置文件 npm config set sharp_binary_host "https://npmmirror.com/mirrors/sharp" npm config set sharp_libvips_binary_host "https://npmmirror.com/mirrors/sharp-libvips" -### rollup打包 +#### rollup打包 看不懂webpack的逻辑,直接增加rollup打包,思路就清晰了 npm install rollup --save-dev npm install @rollup/plugin-typescript --save-dev @@ -22,12 +26,12 @@ npm install rollup-plugin-rawsvg --save-dev - 2024-1, 作者发布新版2.0了,暂时不去私自编译了,可以直接使用npm包了。之前这样处理是因为作者有很长一个版本的锁定,没有正式发布,版本后不能切换到开放模式,自己打包提取核心功能以便工程需要。 -## modules +### modules -### clipboard +#### clipboard 复制剪切板 -### image +#### image 内部的image的sanitize时,只支持http,https,data这三种模型,其他情况会赋值为'//:0' 比如拦截时,url需要临时设置成blob:http @@ -37,20 +41,20 @@ image.sanitize = (url) => url; ``` -## [delta](https://github.com/quilljs/delta) +### [delta](https://github.com/quilljs/delta) Delta 是用于描述富文本文档结构的内容与变更。由于其描述的通用性,quill.js 将其独立维护。它的数据结构是基于 JSON 格式的,方便服务间进行互解析 [An O(ND) Difference Algorithm and Its Variations](https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.4.6927&rep=rep1&type=pdf)在[github上的实现](https://github.com/jhchen/fast-diff) [Diff, Match and Patch library](https://neil.fraser.name/news/2007/10/09/)在[GitHub](https://github.com/google/diff-match-patch/)上的地址 -## [parchment](https://github.com/quilljs/parchment) +### [parchment](https://github.com/quilljs/parchment) Parchment is Quill's document model. It is a parallel tree structure to the DOM tree, and provides functionality useful for content editors, like Quill. A Parchment tree is made up of Blots, which mirror a DOM node counterpart. Blots can provide structure, formatting, and/or content. Attributors can also provide lightweight formatting information. 通过Parchment你可以自定义出Quill能够识别的内容和格式,或者添加全新的内容和格式。 [一个例子](https://kang-bing-kui.gitbook.io/quill/zhi-nan-guides/clonewithparchment) -# [tinymce](https://www.tiny.cloud/docs/tinymce/latest/) +## [tinymce](https://www.tiny.cloud/docs/tinymce/latest/) > 自己需要一个编辑器,用来编辑并保存为HTML5格式,且需要数学公式,就需要这个强大的编辑器 - [github项目](https://github.com/lmj01/tinymce) @@ -59,7 +63,7 @@ Parchment is Quill's document model. It is a parallel tree structure to the DOM 插件的写法可参考安装后的code插件来写。 modules\tinymce\src\core\main\ts\api\Options.ts -# jszip +## jszip ```javascript new Promise(()=>{ @@ -86,9 +90,14 @@ new Promise(()=>{ ``` -# [node-gyp](https://github.com/nodejs/node-gyp) +## [node-gyp](https://github.com/nodejs/node-gyp) node-gyp is a cross-platform command-line tool written in Node.js for compiling native addon modules for Node.js. It contains a vendored copy of the gyp-next project that was previously used by the Chromium team and extended to support the development of Node.js native addons. +## [Daikon](https://github.com/rii-mango/Daikon) + +## [Mock Service Worker](https://mswjs.io/) +Industry standard API mocking for JavaScript. + # 其他库 - [excel](/articles/notes/excel.md) \ No newline at end of file diff --git a/web/nginx/9930.conf b/web/nginx/9930.conf index ef995c6..776e08f 100644 --- a/web/nginx/9930.conf +++ b/web/nginx/9930.conf @@ -21,6 +21,19 @@ server { add_header Cross-Origin-Embedder-Policy require-corp; add_header Cross-Origin-Opener-Policy same-origin; + # cors + add_header 'Access-Control-Allow-Origin' $http_origin; + add_header 'Access-Control-Allow-Credentials' 'true'; + add_header 'Access-Control-Allow-Methods' 'GET,POST,OPTIONS'; + add_header 'Access-Control-Allow-Headers' 'DNT,web-token,app-token,Authorization,Accept,Origin,Keep-Alive,User-Agent,X-Mx-ReqToken,X-Data-Type,X-Auth-Token,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range'; + add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range'; + if ($request_method = 'OPTIONS') { + add_header 'Access-Control-Max-Age' 1728000; + add_header 'Content-Type' 'text/plain;charset=utf-8'; + add_header 'Content-Length' 0; + return 204; + } + default_type text/html; index index.html index.htm; } diff --git a/web/nginx/nginx.md b/web/nginx/nginx.md index ac9839d..4e7d0c5 100644 --- a/web/nginx/nginx.md +++ b/web/nginx/nginx.md @@ -39,4 +39,5 @@ include ./conf.d/*.conf; location = > location full-path > location ^~ path > location ~,~* > location part-path > location / -[在线配置nginx](https://www.digitalocean.com/community/tools/nginx?global.app.lang=zhCN) \ No newline at end of file +[在线配置nginx](https://www.digitalocean.com/community/tools/nginx?global.app.lang=zhCN) +[正确的Nginx跨域配置(后端Nginx CORS跨域配置、CORS设置,后端允许跨域请求)](https://www.cnblogs.com/zhoading/p/15987927.html) \ No newline at end of file diff --git a/web/pkg.md b/web/pkg.md index 289fc3c..3eaaeea 100644 --- a/web/pkg.md +++ b/web/pkg.md @@ -1,17 +1,15 @@ # [node](https://nodejs.org/en) -## update +- [api doc](https://nodejs.org/docs/latest/api/) ```js +node --watch index.js // v18.15.0后增加的,可以不用每次都输入,直接关联某个文件的变化 node --harmony script.js --version --help --harmony 传递给node参数的修饰 -npm install -g n 非window上使用n来管理 -npm config list ``` -# 包管理 - +## 包管理 -## [npm](https://docs.npmjs.com/) +### [npm](https://docs.npmjs.com/) [npm-config](https://docs.npmjs.com/cli/v10/commands/npm-config) @@ -19,6 +17,7 @@ npm config list npm init // 初始化工程 npm init -w ./packages/a // 创建子包 npm install libraryX --workspace packages/pA // 子工作区按照特定依赖 +npm install libraryX --save-dev --workspaces // 安装 npm i libraryX -w packages/pA npm install XXX 安装但不写入package.json npm install XXX --save 安装且写入package.json中的dependencies @@ -48,7 +47,7 @@ npm cache clean --force npm config list ``` -## [pnpm](https://pnpm.io/) +### [pnpm](https://pnpm.io/) - [中文文档](https://pnpm.io/zh/motivation) @@ -63,7 +62,7 @@ pnpm add react -w // 全局公共依赖 pnpm add react --filter pkg1 // 指定项目按照 ``` -## [Yarn is a package manager](https://yarnpkg.com/) +### [Yarn is a package manager](https://yarnpkg.com/) - [yarn add](https://classic.yarnpkg.com/en/docs/cli/add) @@ -100,6 +99,7 @@ Vue-cli3开始把webpack.config.js隐藏在node_modules/@vue/cli-service/webpack ### [Parcel](https://parceljs.org/docs/) Parcel is a zero configuration build tool for the web +Parcel默认把所有文件打包进js包中,不存在单独的静态文件目录,需要借助插件来完成[parcel-reporter-static-files-copy](https://www.npmjs.com/package/parcel-reporter-static-files-copy) ## 相关库