按照CSS-Tricks https://css-tricks.com/gulp-for-wordpress-creating-the-tasks/上的本教程进行操作后,一切工作都非常顺畅,但是当我更改文件时浏览器会重新加载:
似乎停留在“重新加载浏览器”上。我知道有关此问题的所有不同回复,但没有一个解决了我的问题。 因此,我认为这可能与MAMP及其本地服务器配置有关?
这是我的Gulp配置代码。有关信息,我也尝试按照本教程中的说明设置流,但是问题是相同的。
public class DbClientStore : IClientStore
{
IDNHClientsServices clientsService;
protected IStaticCacheManager cacheManager ;
public DbClientStore(IDNHClientsServices repository, IStaticCacheManager staticCacheManager)
{
clientsService = repository;
cacheManager = staticCacheManager;
}
/// <summary>
/// Dùng để get client secrect trong db trung quá trình runtime
/// </summary>
/// <param name="clientId"></param>
/// <returns></returns>
public Task<Client> FindClientByIdAsync(string clientId)
{
ClientsResponse client = cacheManager.Get(string.Format("clientkey.{0}", clientId), () => clientsService.GetClientInfo(clientId).Result);
if (client == null)
{
return Task.FromResult<Client>(null);
}
ICollection<string> type = null;
switch (client.AllowedGrantTypes)
{
case GrantType.ResourceOwnerPassword:
type = GrantTypes.ResourceOwnerPassword;
break;
case GrantType.ClientCredentials:
type = GrantTypes.ClientCredentials;
break;
default:
type = GrantTypes.ResourceOwnerPassword;
break;
}
return Task.FromResult(new Client()
{
ClientId = client.clientId,
AllowedGrantTypes = type,
AllowedScopes = client.AllowedScopes,
ClientSecrets = client.ClientSecrets
});
}
}
public class ClientsResponse
{
public int Id { get; set; }
public string clientId { get; set; }
public string RedirectUris { get; set; }
public string AllowedGrantTypes { get; set; }
public bool Enable { get; set; }
public DateTime? CreatedDate { get; set; }
public DateTime? UpdateDate { get; set; }
public ICollection<string> AllowedScopes { get; set; }
public ICollection<Secret> ClientSecrets { get; set; }
}
感谢您的阅读!
答案 0 :(得分:0)
如果其他人有此问题,我切换到本地而不是Mamp Pro,问题已“解决”。