计算机名词:shim
shim:谷歌翻译:
shim的定义
an aluminum shim reduces the diameter so that a standard stem will fit
在 Web 上指 Polyfill, 为了填平不同平台不同版本不同浏览器对接口实现的差异
https://softwareengineering.stackexchange.com/questions/66962/are-wrapper-and-shim-synonymous
A shim is typically something written specifically to maintain backwards compatibility. For example, if you have two versions of an API, version 1 and version 2, then rather than maintaining version 1 independently of version 2, you might write a shim that intercepts calls to version 1 of the API, translates the parameters to what version 2 requires, and then returns the results.
Typically, a shim is written by the provider of the API, rather than consumer.
A wrapper is written by the consumer of an API and is typically written so that you can switch the underlying API without the rest of your code having to know. For example, you might write a database wrapper so that you can talk to MS SQL Server, or Oracle, just by switching wrappers.
Of course, as with any terminology, there are gray areas, but I think the above covers the main differences.