PageSourceSearch

https://s1.himalaya.com/hmly-static/hmly-next-static/2.53.4/yx_pub…/pages/article-3daf00c9cff22bbf54be.js

js himalaya.com collected 2026-10-01 11:28:57 UTC 10,840 bytes, 1 lines download raw bytes

1_N_E=(window.webpackJsonp_N_E=window.webpackJsonp_N_E||[]).push([[29],{"2qu3":function(e,t,r){"use strict";var n=r("oI91"),o=r("/GRZ"),a=r("i2R6");function u(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?u(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):u(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function l(e,t){var r;if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"===typeof e)return c(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return c(e,t)}(e))||t&&e&&"number"===typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,u=!0,i=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return u=e.done,e},e:function(e){i=!0,a=e},f:function(){try{u||null==r.return||r.return()}finally{if(i)throw a}}}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}t.__esModule=!0,t.default=void 0;var s,d=(s=r("q1tI"))&&s.__esModule?s:{default:s},f=r("8L3h"),p=r("jwwS");var b=[],h=[],m=!1;function y(e){var t=e(),r={loading:!0,loaded:null,error:null};return r.promise=t.then((function(e){return r.loading=!1,r.loaded=e,e})).catch((function(e){throw r.loading=!1,r.error=e,e})),r}function v(e){var t={loading:!1,loaded:{},error:null},r=[];try{Object.keys(e).forEach((function(n){var o=y(e[n]);o.loading?t.loading=!0:(t.loaded[n]=o.loaded,t.error=o.error),r.push(o.promise),o.promise.then((function(e){t.loaded[n]=e})).catch((function(e){t.error=e}))}))}catch(n){t.error=n}return t.promise=Promise.all(r).then((function(e){return t.loading=!1,e})).catch((function(e){throw t.loading=!1,e})),t}function _(e,t){return d.default.createElement(function(e){return e&&e.__esModule?e.default:e}(e),t)}function O(e,t){var r=Object.assign({loader:null,loading:null,delay:200,timeout:null,render:_,webpack:null,modules:null},t),n=null;function o(){if(!n){var t=new g(e,r);n={getCurrentValue:t.getCurrentValue.bind(t),subscribe:t.subscribe.bind(t),retry:t.retry.bind(t),promise:t.promise.bind(t)}}return n.promise()}if(!m&&"function"===typeof r.webpack){var a=r.webpack();h.push((function(e){var t,r=l(a);try{for(r.s();!(t=r.n()).done;){var n=t.value;if(-1!==e.indexOf(n))return o()}}catch(u){r.e(u)}finally{r.f()}}))}var u=function(e,t){o();var a=d.default.useContext(p.LoadableContext),u=(0,f.useSubscription)(n);return d.default.useImperativeHandle(t,(function(){return{retry:n.retry}}),[]),a&&Array.isArray(r.modules)&&r.modules.forEach((function(e){a(e)})),d.default.useMemo((function(){return u.loading||u.error?d.default.createElement(r.loading,{isLoading:u.loading,pastDelay:u.pastDelay,timedOut:u.timedOut,error:u.error,retry:n.retry}):u.loaded?r.render(u.loaded,e):null}),[e,u])};return u.preload=function(){return o()},u.displayName="LoadableComponent",d.default.forwardRef(u)}var g=function(){function e(t,r){o(this,e),this._loadFn=t,this._opts=r,this._callbacks=new Set,this._delay=null,this._timeout=null,this.retry()}return a(e,[{key:"promise",value:function(){return this._res.promise}},{key:"retry",value:function(){var e=this;this._clearTimeouts(),this._res=this._loadFn(this._opts.loader),this._state={pastDelay:!1,timedOut:!1};var t=this._res,r=this._opts;t.loading&&("number"===typeof r.delay&&(0===r.delay?this._state.pastDelay=!0:this._delay=setTimeout((function(){e._update({pastDelay:!0})}),r.delay)),"number"===typeof r.timeout&&(this._timeout=setTimeout((function(){e._update({timedOut:!0})}),r.timeout))),this._res.promise.then((function(){e._update({}),e._clearTimeouts()})).catch((function(t){e._update({}),e._clearTimeouts()})),this._update({})}},{key:"_update",value:function(e){this._state=i(i({},this._state),{},{error:this._res.error,loaded:this._res.loaded,loading:this._res.loading},e),this._callbacks.forEach((function(e){return e()}))}},{key:"_clearTimeouts",value:function(){clearTimeout(this._delay),clearTimeout(this._timeout)}},{key:"getCurrentValue",value:function(){return this._state}},{key:"subscribe",value:function(e){var t=this;return this._callbacks.add(e),function(){t._callbacks.delete(e)}}}]),e}();function w(e){return O(y,e)}function j(e,t){for(var r=[];e.length;){var n=e.pop();r.push(n(t))}return Promise.all(r).then((function(){if(e.length)return j(e,t)}))}w.Map=function(e){if("function"!==typeof e.render)throw new Error("LoadableMap requires a `render(loaded, props)` function");return O(v,e)},w.preloadAll=function(){return new Promise((function(e,t){j(b).then(e,t)}))},w.preloadReady=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return new Promise((function(t){var r=function(){return m=!0,t()};j(h,e).then(r,r)}))},window.__NEXT_PRELOADREADY=w.preloadReady;var k=w;t.default=k},"Hq/4":function(e,t,r){"use strict";r.r(t);var n=r("o0o1"),o=r.n(n),a=r("HaE+"),u=r("q1tI"),i=r.n(u),l=r("wx14"),c=r("Om3U"),s=r("DTM/"),d=r("0lfv");var f=function(e){var t=e.albums,r=e.episodes,n=Object(u.useState)([]),o=n[0],a=n[1],i=Object(u.useState)([]),l=i[0],c=i[1];return Object(u.useEffect)((function(){var e,n;
1if(0!==t.length&&Promise.all((e=t,n=s.c.getAlbumInfo,e.map((function(e){return n(e)})))).then((function(e){var t=e.map((function(e){return e.data}));a(t)})).catch((function(e){d.pb.error({desc:"Get album",err:e})})),0!==r.length){var o=r.join(",");s.A.getShareEpisodeInfoLists(o).then((function(e){c(e.list)})).catch((function(e){d.pb.error({desc:"Get episode",err:e})}))}}),[t,r]),{albumResults:o,episodesResults:l}},p=r("D5+a"),b=r("aoTL"),h=r("Vvt1"),m=r.n(h),y=r("83g6"),v=r("SMKl"),_=i.a.createElement,O=m()((function(){return Promise.all([r.e(16),r.e(92)]).then(r.bind(null,"wMmC"))}),{loadableGenerated:{webpack:function(){return["wMmC"]},modules:["./pc"]}}),g=m()((function(){return r.e(93).then(r.bind(null,"qHOx"))}),{loadableGenerated:{webpack:function(){return["qHOx"]},modules:["./mobile"]}}),w=Object(b.b)((function(e){var t=Object(p.b)().rootStore,r=e.albums,n=e.episodes,o=e.theme,a=e.articleId,u=t.ua,i=t.isInApp,s=t.isLogin,d=u.viewport,b=f({albums:r,episodes:n}),h=b.albumResults,m=b.episodesResults;return Object(y.p)({screen_type:v.b.DIGEST,screen_id:a}),_(c.a,{isHeaderFixed:!1,theme:o},_(d?g:O,Object(l.a)({albumResults:h,episodesResults:m,isInApp:i,isLogin:s},e)))})),j=r("21WQ"),k=r("diKu"),P=r("J0kB"),S=r("Hnjf"),E=i.a.createElement;function D(e){var t=e.split("/"),r=t[t.length-1].split("-");return r[r.length-1]}var I=function(e){return E(w,e)};I.getInitialProps=function(){var e=Object(a.a)(o.a.mark((function e(t){var r,n,a,u,i,l,c,f,p,b,h,m,y,_,O,g,w;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=Object(d.jb)()?null===t||void 0===t||null===(r=t.res)||void 0===r?void 0:r.cookie:document.cookie,a="",u="",Object(d.jb)()?(a=null===(i=t.query)||void 0===i?void 0:i.articleId,u=null===(l=t.query)||void 0===l?void 0:l.dark):(c=window.location.pathname,f=S.qs.parse(window.location.search.substring(1)),a=D(c),u=f.dark),p=j.a.light,"on"===u&&(p=j.a.dark),e.prev=6,e.next=9,s.d.fetchArticleById(a,n);case 9:if(0!==(h=e.sent).ret||!h.data){e.next=17;break}m=h.data,(b=m).content=JSON.parse(m.content),b.remark=m.remark&&JSON.parse(m.remark)||{},e.next=20;break;case 17:return d.pb.error({desc:"No response articleId"}),Object(d.vb)({ctx:t}),e.abrupt("return",{});case 20:e.next=27;break;case 22:return e.prev=22,e.t0=e.catch(6),d.pb.error({desc:"Parse article content error",error:e.t0}),Object(d.vb)({ctx:t}),e.abrupt("return",{});case 27:return y=b.content,_=Object(k.isDeltaStruct)(y),O=_?Object(P.f)(b.remark.html):Object(P.e)(y),g=O.albums,w=O.episodes,e.abrupt("return",{content:y,remark:b.remark,title:b.title,author:{name:b.author,job:b.job,time:b.updatedAt,coverPath:b.albumCoverPath},articleId:b.id,albumId:b.albumId,episodes:w,albums:g,loading:!1,seoDescription:b.description,tags:b.tagList&&b.tagList.map((function(e){return e.name}))||[],coverPath:b.coverPath,pageUrl:Object(d.jb)()?t.req.url:window.location.href,theme:p,isDeltaStruct:_,curPage:v.b.DIGEST});case 32:case"end":return e.stop()}}),e,null,[[6,22]])})));return function(t){return e.apply(this,arguments)}}();t.default=I},Vvt1:function(e,t,r){e.exports=r("a6RD")},a6RD:function(e,t,r){"use strict";var n=r("oI91");function o(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function a(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?o(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):o(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}t.__esModule=!0,t.noSSR=l,t.default=function(e,t){var r=u.default,n={loading:function(e){e.error,e.isLoading;return e.pastDelay,null}};e instanceof Promise?n.loader=function(){return e}:"function"===typeof e?n.loader=e:"object"===typeof e&&(n=a(a({},n),e));if(n=a(a({},n),t),"object"===typeof e&&!(e instanceof Promise)&&(e.render&&(n.render=function(t,r){return e.render(r,t)}),e.modules)){r=u.default.Map;var o={},i=e.modules();
1Object.keys(i).forEach((function(e){var t=i[e];"function"!==typeof t.then?o[e]=t:o[e]=function(){return t.then((function(e){return e.default||e}))}})),n.loader=o}n.loadableGenerated&&delete(n=a(a({},n),n.loadableGenerated)).loadableGenerated;if("boolean"===typeof n.ssr){if(!n.ssr)return delete n.ssr,l(r,n);delete n.ssr}return r(n)};i(r("q1tI"));var u=i(r("2qu3"));function i(e){return e&&e.__esModule?e:{default:e}}function l(e,t){return delete t.webpack,delete t.modules,e(t)}},bWS8:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/article",function(){return r("Hq/4")}])},jwwS:function(e,t,r){"use strict";var n;t.__esModule=!0,t.LoadableContext=void 0;var o=((n=r("q1tI"))&&n.__esModule?n:{default:n}).default.createContext(null);t.LoadableContext=o}},[["bWS8",1,2,3,4,11,14,0,5,6,7,8,13]]]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.