repoweaver
Version:
A GitHub App that skillfully weaves multiple templates together to create and update repositories with intelligent merge strategies
1 lines • 1.98 kB
JSON
{"ast":null,"code":"'use strict';\n\nconst assets = [];\nfunction registerAsset(asset) {\n return assets.push(asset);\n}\nfunction getAssetByID(assetId) {\n return assets[assetId - 1];\n}\nmodule.exports = {\n registerAsset,\n getAssetByID\n};","map":{"version":3,"names":["assets","registerAsset","asset","push","getAssetByID","assetId","module","exports"],"sources":["/Users/pmouli/Documents/GitHub.nosync/boots-strapper/mobile/node_modules/@react-native/assets-registry/registry.js"],"sourcesContent":["/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * @flow strict\n * @format\n */\n\n'use strict';\n\n/*::\nexport type AssetDestPathResolver = 'android' | 'generic';\n\nexport type PackagerAsset = {\n +__packager_asset: boolean,\n +fileSystemLocation: string,\n +httpServerLocation: string,\n +width: ?number,\n +height: ?number,\n +scales: Array<number>,\n +hash: string,\n +name: string,\n +type: string,\n +resolver?: AssetDestPathResolver,\n ...\n};\n*/\n\nconst assets /*: Array<PackagerAsset> */ = [];\n\nfunction registerAsset(asset /*: PackagerAsset */) /*: number */ {\n // `push` returns new array length, so the first asset will\n // get id 1 (not 0) to make the value truthy\n return assets.push(asset);\n}\n\nfunction getAssetByID(assetId /*: number */) /*: PackagerAsset */ {\n return assets[assetId - 1];\n}\n\n// eslint-disable-next-line lint/no-commonjs-exports\nmodule.exports = {registerAsset, getAssetByID};\n"],"mappings":"AAUA,YAAY;;AAoBZ,MAAMA,MAAM,GAA+B,EAAE;AAE7C,SAASC,aAAaA,CAACC,KAAK,EAAqC;EAG/D,OAAOF,MAAM,CAACG,IAAI,CAACD,KAAK,CAAC;AAC3B;AAEA,SAASE,YAAYA,CAACC,OAAO,EAAqC;EAChE,OAAOL,MAAM,CAACK,OAAO,GAAG,CAAC,CAAC;AAC5B;AAGAC,MAAM,CAACC,OAAO,GAAG;EAACN,aAAa;EAAEG;AAAY,CAAC","ignoreList":[]},"metadata":{"hasCjsExports":true},"sourceType":"script","externalDependencies":[]}