機能の初期パラメータを設定した後、それらを更新する方法がわかりません。
私はserialScrollというプラグインを使用しています。プラグインは、初期の$(elem).serialScroll({// ...})セットアップで示されたアイテムにスクロールします。
私がやりたいのは、ユーザーがページを操作するときにそのアイテムの名前を再定義することです。私は、ユーザーがスクロールするときに情報を正常に取得している別の変数を持っています。
私がやりたいのは、serialScroll({)}にその変数に応じて「item: _ 」フィールドを更新させることだけです。
serialScrollコードは次のとおりです。
var nextClass = ".fig4";
// this is being changed to .figN depending on the users
// scrolling position in the browser/viewport (successfully).
// For proof of communication purposes I forced nextClass
// here to equal .fig4 to see if the two are at lest talking to
// each other, which they are... but now how do i update "items:"
// below to reflect the change in the "nextClass" variable?
$('html').serialScroll({
target:'body',
items: nextClass,
next:'#nextImage',
axis:'y',
duration:700,
force:true,
});