#215 #352 Allow setting start day of week in locale
Hi there,
I made a simple change to allow locale to have an `weekStart` setting to set whether Sunday or Monday should be the first day, to resolve #215 and #352 . And updated docs accordingly.

Pls check.
There are some handy methods in moment.js like `.startOf('isoWeek')`, `.isoWeekday(1)`. They are very useful when Monday is the first day of week in current locale.

I didn't found any similar methods, are they exists? 
ISO weeks (start from monday)?
diff --git a/docs/en/I18n.md b/docs/en/I18n.md
index 0e04268b8..d931d32ed 100644
--- a/docs/en/I18n.md
+++ b/docs/en/I18n.md
@@ -81,6 +81,7 @@ const localeObject = {
   weekdays: 'Domingo_Lunes ...'.split('_'), // weekdays Array
   weekdaysShort: 'Sun_M'.split('_'), // OPTIONAL, short weekdays Array, use first three letters if not provided
   weekdaysMin: 'Su_Mo'.split('_'), // OPTIONAL, min weekdays Array, use first two letters if not provided
+  weekStart: 1, // OPTIONAL, set the start of a week. If the value is 1, Monday will be the start of week instead of Sunday。
   months: 'Enero_Febrero ... '.split('_'), // months Array
   monthsShort: 'Jan_F'.split('_'), // OPTIONAL, short months Array, use first three letters if not provided
   ordinal: n => `${n}º`, // ordinal Function (number) => return number + output
diff --git a/docs/ja/I18n.md b/docs/ja/I18n.md
index 4110f1f95..eb8f138f8 100644
--- a/docs/ja/I18n.md
+++ b/docs/ja/I18n.md
@@ -83,6 +83,7 @@ const localeObject = {
   weekdays: 'Domingo_Lunes ...'.split('_'), // 曜日の配列
   weekdaysShort: 'Sun_M'.split('_'), // OPTIONAL, short weekdays Array, use first three letters if not provided
   weekdaysMin: 'Su_Mo'.split('_'), // OPTIONAL, min weekdays Array, use first two letters if not provided
+  weekStart: 1, // OPTIONAL, 最初の曜日を指定する。０は日曜日です。１は月曜日です。
   months: 'Enero_Febrero ... '.split('_'), // 月の配列
   monthsShort: 'Jan_F'.split('_'), // OPTIONAL, short months Array, use first three letters if not provided
   ordinal: n => `${n}º`, // 序数 Function (number) => return number + output
diff --git a/docs/ko/I18n.md b/docs/ko/I18n.md
index 17cacfb46..6252a0d92 100644
--- a/docs/ko/I18n.md
+++ b/docs/ko/I18n.md
@@ -81,6 +81,7 @@ const localeObject = {
   weekdays: 'Domingo_Lunes ...'.split('_'), // weekdays Array
   weekdaysShort: 'Sun_M'.split('_'), // OPTIONAL, short weekdays Array, use first three letters if not provided
   weekdaysMin: 'Su_Mo'.split('_'), // OPTIONAL, min weekdays Array, use first two letters if not provided
+  weekStart: 1, // OPTIONAL, set the start of a week. If the value is 1, Monday will be the start of week instead of Sunday。
   months: 'Enero_Febrero ... '.split('_'), // months Array
   monthsShort: 'Jan_F'.split('_'), // OPTIONAL, short months Array, use first three letters if not provided
   ordinal: n => `${n}º`, // ordinal Function (number) => return number + output
diff --git a/docs/pt-br/I18n.md b/docs/pt-br/I18n.md
index b6c4f23fe..efdc8ec40 100644
--- a/docs/pt-br/I18n.md
+++ b/docs/pt-br/I18n.md
@@ -81,6 +81,7 @@ const objetoLocale = {
   weekdays: 'Domingo_Lunes ...'.split('_'), // dias da semana: Array
   weekdaysShort: 'Sun_M'.split('_'), // OPCIONAL, dias da semana com nome curto: Array, utiliza as três primeiras letras se nenhuma for especificada
   weekdaysMin: 'Su_Mo'.split('_'), // OPCIONAL, dias da semana com nome mínimo: Array, utiliza as duas primeiras letras se nenhuma for especificada
+  weekStart: 1, // OPTIONAL, set the start of a week. If the value is 1, Monday will be the start of week instead of Sunday。
   months: 'Enero_Febrero ... '.split('_'), // meses: Array
   monthsShort: 'Jan_F'.split('_'), // OPCIONAL, meses com nome curto: Array, utiliza as três primeiras letras se nenhuma for especificada
   ordinal: n => `${n}º`, // ordinal: Function (number) => retorna number + saída
diff --git a/docs/zh-cn/I18n.md b/docs/zh-cn/I18n.md
index e95566e37..82d92907f 100644
--- a/docs/zh-cn/I18n.md
+++ b/docs/zh-cn/I18n.md
@@ -81,6 +81,7 @@ const localeObject = {
   weekdays: 'Domingo_Lunes ...'.split('_'), // 星期 Array
   weekdaysShort: 'Sun_M'.split('_'), // 可选, 短的星期 Array, 如果没提供则使用前三个字符
   weekdaysMin: 'Su_Mo'.split('_'), // 可选, 最短的星期 Array, 如果没提供则使用前两个字符
+  weekStart: 1, // 可选，指定一周的第一天。默认为0，即周日。如果为1，则周一为一周得第一天。
   months: 'Enero_Febrero ... '.split('_'), // 月份 Array
   monthsShort: 'Jan_F'.split('_'), // 可选, 短的月份 Array, 如果没提供则使用前三个字符
   ordinal: n => `${n}º`, // 序号生成工厂函数 Function (number) => return number + output
diff --git a/src/index.js b/src/index.js
index 972e26120..d118279e4 100644
--- a/src/index.js
+++ b/src/index.js
@@ -171,9 +171,12 @@ class Dayjs {
       case C.M:
         return isStartOf ? instanceFactory(1, this.$M) :
           instanceFactory(0, this.$M + 1)
-      case C.W:
-        return isStartOf ? instanceFactory(this.$D - this.$W, this.$M) :
-          instanceFactory(this.$D + (6 - this.$W), this.$M)
+      case C.W: {
+        const l = this.$locale()
+        const weekStart = l && l.weekStart === 1 ? 1 : 0
+        return isStartOf ? instanceFactory(this.$D - (this.$W - weekStart), this.$M) :
+          instanceFactory(this.$D + (6 - (this.$W - weekStart)), this.$M)
+      }
       case C.D:
       case C.DATE:
         return instanceFactorySet('setHours', 0)

diff --git a/test/manipulate.test.js b/test/manipulate.test.js
index 6a85769ff..98663ded7 100644
--- a/test/manipulate.test.js
+++ b/test/manipulate.test.js
@@ -20,6 +20,10 @@ describe('StartOf EndOf', () => {
     })
   })
 
+  it('StartOf EndOf Week with week start setting', () => {
+    expect(dayjs().locale({ name: 'test', weekStart: 1 }).startOf('week').valueOf()).toBe(moment().startOf('week').add(1, 'day').valueOf())
+  })
+
   it('StartOf EndOf Other -> no change', () => {
     expect(dayjs().startOf('otherString').valueOf()).toBe(moment().startOf('otherString').valueOf())
     expect(dayjs().endOf('otherString').valueOf()).toBe(moment().endOf('otherString').valueOf())

{"test/manipulate.test.js": {"run": "PASS", "test": "FAIL", "fix": "PASS"}}
{"test/plugin.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/get-set.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/comparison.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/isLeapYear.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/query.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/quarterOfYear.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/advancedFormat.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/timezone.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/isSameOrBefore.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/locale/keys.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/locale.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/utils.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/relativeTime.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/parse.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/customParseFormat.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/localizableFormat.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/dayOfYear.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/buddhistEra.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/constructor.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/isSameOrAfter.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/weekOfYear.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}, "test/plugin/isBetween.test.js": {"run": "PASS", "test": "PASS", "fix": "PASS"}}
{"test/manipulate.test.js": {"run": "PASS", "test": "FAIL", "fix": "PASS"}}
{"passed_count": 23, "failed_count": 1, "skipped_count": 0, "passed_tests": ["test/plugin.test.js", "test/get-set.test.js", "test/plugin/quarterOfYear.test.js", "test/plugin/advancedFormat.test.js", "test/timezone.test.js", "test/plugin/isSameOrBefore.test.js", "test/locale/keys.test.js", "test/utils.test.js", "test/plugin/relativeTime.test.js", "test/parse.test.js", "test/plugin/localizableFormat.test.js", "test/constructor.test.js", "test/plugin/isSameOrAfter.test.js", "test/plugin/weekOfYear.test.js", "test/comparison.test.js", "test/plugin/isLeapYear.test.js", "test/query.test.js", "test/locale.test.js", "test/plugin/customParseFormat.test.js", "test/plugin/dayOfYear.test.js", "test/manipulate.test.js", "test/plugin/buddhistEra.test.js", "test/plugin/isBetween.test.js"], "failed_tests": ["test/display.test.js"], "skipped_tests": []}
{"passed_count": 22, "failed_count": 2, "skipped_count": 0, "passed_tests": ["test/plugin.test.js", "test/get-set.test.js", "test/plugin/quarterOfYear.test.js", "test/plugin/advancedFormat.test.js", "test/timezone.test.js", "test/plugin/isSameOrBefore.test.js", "test/locale/keys.test.js", "test/utils.test.js", "test/plugin/relativeTime.test.js", "test/parse.test.js", "test/plugin/localizableFormat.test.js", "test/constructor.test.js", "test/plugin/isSameOrAfter.test.js", "test/plugin/weekOfYear.test.js", "test/plugin/isLeapYear.test.js", "test/comparison.test.js", "test/query.test.js", "test/locale.test.js", "test/plugin/customParseFormat.test.js", "test/plugin/dayOfYear.test.js", "test/plugin/buddhistEra.test.js", "test/plugin/isBetween.test.js"], "failed_tests": ["test/manipulate.test.js", "test/display.test.js"], "skipped_tests": []}
{"passed_count": 23, "failed_count": 1, "skipped_count": 0, "passed_tests": ["test/plugin.test.js", "test/get-set.test.js", "test/plugin/quarterOfYear.test.js", "test/plugin/advancedFormat.test.js", "test/timezone.test.js", "test/plugin/isSameOrBefore.test.js", "test/locale/keys.test.js", "test/utils.test.js", "test/plugin/relativeTime.test.js", "test/parse.test.js", "test/plugin/localizableFormat.test.js", "test/constructor.test.js", "test/plugin/isSameOrAfter.test.js", "test/plugin/weekOfYear.test.js", "test/plugin/isLeapYear.test.js", "test/comparison.test.js", "test/query.test.js", "test/locale.test.js", "test/plugin/customParseFormat.test.js", "test/plugin/dayOfYear.test.js", "test/plugin/buddhistEra.test.js", "test/manipulate.test.js", "test/plugin/isBetween.test.js"], "failed_tests": ["test/display.test.js"], "skipped_tests": []}